From 854df7df0c2c9f5af095dc932b35038e2cd18ac5 Mon Sep 17 00:00:00 2001 From: spo Date: Wed, 15 Jun 2016 17:03:23 +0300 Subject: [PATCH] Fix return ModelHighAPI_Selection from list as a copy --- src/ModelHighAPI/ModelHighAPI.i | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/ModelHighAPI/ModelHighAPI.i b/src/ModelHighAPI/ModelHighAPI.i index 03df07c00..1a043be26 100644 --- a/src/ModelHighAPI/ModelHighAPI.i +++ b/src/ModelHighAPI/ModelHighAPI.i @@ -108,6 +108,11 @@ } } +%typemap(out) const ModelHighAPI_Selection & { + $1_basetype * ptr = new $1_basetype(*$1); + $result = SWIG_NewPointerObj( (void*) ptr, $1_descriptor, 1 ); +} + // all supported interfaces %include "ModelHighAPI_Double.h" %include "ModelHighAPI_Integer.h" -- 2.39.2