summaryrefslogtreecommitdiff
path: root/pidl/lib/Parse/Pidl/Samba4/Python.pm
diff options
context:
space:
mode:
Diffstat (limited to 'pidl/lib/Parse/Pidl/Samba4/Python.pm')
-rw-r--r--pidl/lib/Parse/Pidl/Samba4/Python.pm11
1 files changed, 9 insertions, 2 deletions
diff --git a/pidl/lib/Parse/Pidl/Samba4/Python.pm b/pidl/lib/Parse/Pidl/Samba4/Python.pm
index 82f92195742..f2cb5387751 100644
--- a/pidl/lib/Parse/Pidl/Samba4/Python.pm
+++ b/pidl/lib/Parse/Pidl/Samba4/Python.pm
@@ -237,9 +237,16 @@ sub PythonStruct($$$$$$)
$self->pidl("static PyGetSetDef ".$getsetters."[] = {");
$self->indent;
foreach my $e (@{$d->{ELEMENTS}}) {
- $self->pidl("{ discard_const_p(char, \"$e->{NAME}\"), py_$name\_get_$e->{NAME}, py_$name\_set_$e->{NAME} },");
+ $self->pidl("{");
+ $self->indent;
+ $self->pidl(".name = discard_const_p(char, \"$e->{NAME}\"),");
+ $self->pidl(".get = py_$name\_get_$e->{NAME},");
+ $self->pidl(".set = py_$name\_set_$e->{NAME},");
+ $self->pidl(".doc = discard_const_p(char, \"PIDL-generated element $e->{NAME}\")");
+ $self->deindent;
+ $self->pidl("},");
}
- $self->pidl("{ NULL }");
+ $self->pidl("{ .name = NULL }");
$self->deindent;
$self->pidl("};");
$self->pidl("");