aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorHugo Lima <hugo.lima@openbossa.org>2009-11-27 19:50:48 -0200
committerHugo Lima <hugo.lima@openbossa.org>2009-11-30 13:56:28 -0200
commit0986fe76a6caedcd77d0334efe2c09e38ff2a087 (patch)
tree133dbba6ded11b80bdb6b06b9a57124df7123ebf /tests
parent78bf7bca1fe92052ae7b64827ae81bbe25bd8c3d (diff)
Add the generator flag "enable-parent-ctor-heuristic".
When enabled, this heuristic will check every constructor for an argument named "parent", if the argument is a pointer, then it'll be the parent of this object.
Diffstat (limited to 'tests')
-rw-r--r--tests/samplebinding/CMakeLists.txt2
-rw-r--r--tests/samplebinding/typesystem_sample.xml5
2 files changed, 1 insertions, 6 deletions
diff --git a/tests/samplebinding/CMakeLists.txt b/tests/samplebinding/CMakeLists.txt
index 4529056ed..a9d2118fd 100644
--- a/tests/samplebinding/CMakeLists.txt
+++ b/tests/samplebinding/CMakeLists.txt
@@ -59,7 +59,7 @@ ${CMAKE_CURRENT_BINARY_DIR}/sample/virtualmethods_wrapper.cpp
find_program(GENERATOR generatorrunner REQUIRED)
add_custom_command(OUTPUT ${sample_SRC}
-COMMAND ${GENERATOR} --generatorSet=${shiboken_BINARY_DIR}/shiboken_generator
+COMMAND ${GENERATOR} --generatorSet=${shiboken_BINARY_DIR}/shiboken_generator --enable-parent-ctor-heuristic
${CMAKE_CURRENT_SOURCE_DIR}/global.h
--include-paths=${libsample_SOURCE_DIR}
--typesystem-paths=${CMAKE_CURRENT_SOURCE_DIR}
diff --git a/tests/samplebinding/typesystem_sample.xml b/tests/samplebinding/typesystem_sample.xml
index 1b0228d64..ab4696d14 100644
--- a/tests/samplebinding/typesystem_sample.xml
+++ b/tests/samplebinding/typesystem_sample.xml
@@ -64,11 +64,6 @@
<modify-function signature="event(Event*)">
<modify-argument index="1" invalidate-after-use="yes"/>
</modify-function>
- <modify-function signature="ObjectType(ObjectType*)">
- <modify-argument index="1">
- <parent index="this" action="add"/>
- </modify-argument>
- </modify-function>
<modify-function signature="create()">
<modify-argument index="return">
<define-ownership owner="target"/>