summaryrefslogtreecommitdiffstats
path: root/tests/samplebinding/typesystem_sample.xml
diff options
context:
space:
mode:
authorMarcelo Lira <marcelo.lira@openbossa.org>2010-12-06 14:30:33 -0300
committerMarcelo Lira <marcelo.lira@openbossa.org>2010-12-06 16:39:26 -0300
commitff592945dbf0cb990ca13d60f480eeead7e34a99 (patch)
tree6ea9b6395caa3181dfbc8bad2b8197b66f8624d7 /tests/samplebinding/typesystem_sample.xml
parentee4f78f615160b65b2d8f3f11a6735fd7da9f0fc (diff)
downloadshiboken-ff592945dbf0cb990ca13d60f480eeead7e34a99.tar.gz
shiboken-ff592945dbf0cb990ca13d60f480eeead7e34a99.tar.xz
shiboken-ff592945dbf0cb990ca13d60f480eeead7e34a99.zip
Test case for proper generation of constructor altered by conversion-rule tag.
Reviewed by Hugo Parente <hugo.lima@openbossa.org> Reviewed by Luciano Wolf <luciano.wolf@openbossa.org>
Diffstat (limited to 'tests/samplebinding/typesystem_sample.xml')
-rw-r--r--tests/samplebinding/typesystem_sample.xml13
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/samplebinding/typesystem_sample.xml b/tests/samplebinding/typesystem_sample.xml
index fb133b51..f0a78e1e 100644
--- a/tests/samplebinding/typesystem_sample.xml
+++ b/tests/samplebinding/typesystem_sample.xml
@@ -1216,6 +1216,19 @@
</add-function>
</value-type>
+ <value-type name="CtorConvRule">
+ <modify-function signature="CtorConvRule(long)">
+ <modify-argument index="1">
+ <!--<replace-type modified-type="long"/>-->
+ <conversion-rule class="native">
+ // Does nothing really, just test the code generation
+ // of constructors whose arguments where
+ long %out = PyInt_AS_LONG(%PYARG_1) + 1;
+ </conversion-rule>
+ </modify-argument>
+ </modify-function>
+ </value-type>
+
<add-function signature="multiplyString(PyString*, unsigned int)" return-type="const char*">
<inject-code class="target" position="beginning">
%PYARG_0 = PyString_FromString("");