From 242f0fa7269e9baf331679dc413c28471b1f7d05 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Mon, 13 Jan 2020 12:56:22 +0100 Subject: shiboken: Fix shared pointer return value in virtual function Smart pointer values did not have a minimal constructor defined, add that. Also add a special case to the return type warning, since that does not have the instantiated type. Fixes: PYSIDE-1188 Change-Id: Ibadd7273f839eb19e1eeb5c912f124e3798207df Reviewed-by: Christian Tismer --- sources/shiboken2/tests/libsmart/smart_obj.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sources/shiboken2/tests/libsmart') diff --git a/sources/shiboken2/tests/libsmart/smart_obj.h b/sources/shiboken2/tests/libsmart/smart_obj.h index e5709a071..8fe45993f 100644 --- a/sources/shiboken2/tests/libsmart/smart_obj.h +++ b/sources/shiboken2/tests/libsmart/smart_obj.h @@ -48,7 +48,7 @@ public: Integer takeInteger(Integer val); SharedPtr giveSharedPtrToObj(); std::vector > giveSharedPtrToObjList(int size); - SharedPtr giveSharedPtrToInteger(); + virtual SharedPtr giveSharedPtrToInteger(); // virtual for PYSIDE-1188 SharedPtr giveSharedPtrToConstInteger(); int takeSharedPtrToConstInteger(SharedPtr pInt); SharedPtr giveSharedPtrToInteger2(); -- cgit v1.2.3