Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
autopybind11
autopybind11
Commits
a200e24b
Commit
a200e24b
authored
Jun 07, 2021
by
John Parent
Browse files
Optional Trampolines
parent
935f5d8a
Pipeline
#232648
passed with stages
in 27 minutes and 23 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
autopybind11/__main__.py
View file @
a200e24b
...
...
@@ -1840,8 +1840,8 @@ class BindingsGenerator:
# TODO: when member method granularity is introduced, use that to determine
# PBR instead of at class level
pbr
=
self
.
customizer
.
get_pass_by_ref
(
class_data
)
tramp_methods
=
self
.
find_tramp_methods
(
instance_data
)
if
self
.
opts
.
enabled_trampoline
:
tramp_methods
=
self
.
find_tramp_methods
(
instance_data
)
# If there exist any virtual functions abiding by certain criteria
# (see find_tramp_methods), we'll need to write out a trampoline implementation
tramp_name
=
""
...
...
@@ -3321,6 +3321,14 @@ def main(argv=None):
dest
=
"ens_flag"
,
default
=
True
,
)
arg
.
add
(
"-et"
,
"--enable-trampolines"
,
action
=
"store"
,
default
=
True
,
type
=
lambda
x
:
bool
(
distutils
.
util
.
strtobool
(
x
)),
dest
=
"enabled_trampoline"
,
)
arg
.
add
(
"-agns"
,
"--apply_global_namespace"
,
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment