aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorChristian Tismer <tismer@stackless.com>2015-12-28 01:17:18 +0100
committerChristian Tismer <tismer@stackless.com>2015-12-28 01:17:18 +0100
commita3c1f3a466bedb842da88a749d5d5b478aa733b7 (patch)
tree2c97e143b6815777b179b6b6b3be41601a5a4c85 /tests
parenta0630c3ad0d009d9737a9ac6f4589c03507166a3 (diff)
parent88c5a194db73ff63984205808b6360759dd58b25 (diff)
Merge pull request #22 from florindinu/generator-metatype-parser
Fix the metatype parser handling of pointer template parameters
Diffstat (limited to 'tests')
-rw-r--r--tests/libsample/CMakeLists.txt1
-rw-r--r--tests/libsample/templateptr.cpp27
-rw-r--r--tests/libsample/templateptr.h37
-rw-r--r--tests/samplebinding/CMakeLists.txt1
-rw-r--r--tests/samplebinding/global.h1
-rw-r--r--tests/samplebinding/typesystem_sample.xml4
6 files changed, 71 insertions, 0 deletions
diff --git a/tests/libsample/CMakeLists.txt b/tests/libsample/CMakeLists.txt
index 30205ed0c..7bbc0c3dd 100644
--- a/tests/libsample/CMakeLists.txt
+++ b/tests/libsample/CMakeLists.txt
@@ -43,6 +43,7 @@ size.cpp
sometime.cpp
str.cpp
strlist.cpp
+templateptr.cpp
transform.cpp
virtualmethods.cpp
expression.cpp
diff --git a/tests/libsample/templateptr.cpp b/tests/libsample/templateptr.cpp
new file mode 100644
index 000000000..a81c7d2cc
--- /dev/null
+++ b/tests/libsample/templateptr.cpp
@@ -0,0 +1,27 @@
+/*
+ * This file is part of the Shiboken Python Binding Generator project.
+ *
+ * Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+ *
+ * Contact: PySide team <contact@pyside.org>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library 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
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#include "templateptr.h"
+
+void TemplatePtr::dummy(std::list<std::pair<BlackBox *, BlackBox *> > & items)
+{
+} \ No newline at end of file
diff --git a/tests/libsample/templateptr.h b/tests/libsample/templateptr.h
new file mode 100644
index 000000000..1402df9f9
--- /dev/null
+++ b/tests/libsample/templateptr.h
@@ -0,0 +1,37 @@
+/*
+ * This file is part of the Shiboken Python Binding Generator project.
+ *
+ * Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+ *
+ * Contact: PySide team <contact@pyside.org>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library 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
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef TEMPLATEPTR_H
+#define TEMPLATEPTR_H
+
+#include <utility>
+#include <list>
+#include "libsamplemacros.h"
+#include "BlackBox.h"
+
+class LIBSAMPLE_API TemplatePtr
+{
+public:
+ void dummy(std::list<std::pair<BlackBox *, BlackBox *> > & items);
+};
+
+#endif
diff --git a/tests/samplebinding/CMakeLists.txt b/tests/samplebinding/CMakeLists.txt
index 836a633e8..8b5ca8799 100644
--- a/tests/samplebinding/CMakeLists.txt
+++ b/tests/samplebinding/CMakeLists.txt
@@ -105,6 +105,7 @@ ${CMAKE_CURRENT_BINARY_DIR}/sample/sonofmderived1_wrapper.cpp
${CMAKE_CURRENT_BINARY_DIR}/sample/str_wrapper.cpp
${CMAKE_CURRENT_BINARY_DIR}/sample/strlist_wrapper.cpp
${CMAKE_CURRENT_BINARY_DIR}/sample/time_wrapper.cpp
+${CMAKE_CURRENT_BINARY_DIR}/sample/templateptr_wrapper.cpp
${CMAKE_CURRENT_BINARY_DIR}/sample/unremovednamespace_wrapper.cpp
${CMAKE_CURRENT_BINARY_DIR}/sample/virtualdaughter_wrapper.cpp
${CMAKE_CURRENT_BINARY_DIR}/sample/virtualdtor_wrapper.cpp
diff --git a/tests/samplebinding/global.h b/tests/samplebinding/global.h
index 007a5e33d..99be4f919 100644
--- a/tests/samplebinding/global.h
+++ b/tests/samplebinding/global.h
@@ -54,6 +54,7 @@
#include "str.h"
#include "strlist.h"
#include "sometime.h"
+#include "templateptr.h"
#include "transform.h"
#include "virtualmethods.h"
#include "voidholder.h"
diff --git a/tests/samplebinding/typesystem_sample.xml b/tests/samplebinding/typesystem_sample.xml
index 49de903bd..a32fbd0c4 100644
--- a/tests/samplebinding/typesystem_sample.xml
+++ b/tests/samplebinding/typesystem_sample.xml
@@ -2395,6 +2395,10 @@
<value-type name="ValueAndVirtual" />
<object-type name="ObjectTypeByValue" />
+
+ <object-type name="TemplatePtr">
+ <modify-function signature="dummy(std::list&lt;std::pair&lt;BlackBox *, BlackBox *&gt; &gt; &amp;)" rename="dummy_method" />
+ </object-type>
<suppress-warning text="horribly broken type '__off64_t'" />
<suppress-warning text="enum '__codecvt_result' does not have a type entry or is not an enum" />