summaryrefslogtreecommitdiff
path: root/cffi
diff options
context:
space:
mode:
authorArmin Rigo <arigo@tunes.org>2022-07-18 15:55:46 +0200
committerArmin Rigo <arigo@tunes.org>2022-07-18 15:55:46 +0200
commitf0a33ae0ce2e62eb3a625c7baef175f385328b17 (patch)
treea7ad2efb5518473f36d97d8d92c4a3894f3d602d /cffi
parentd19553253e3c2967238777b4005abb5dc57f656d (diff)
downloadcffi-f0a33ae0ce2e62eb3a625c7baef175f385328b17.tar.gz
Tentative fix for issue #542
Diffstat (limited to 'cffi')
-rw-r--r--cffi/model.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/cffi/model.py b/cffi/model.py
index ad1c176..1708f43 100644
--- a/cffi/model.py
+++ b/cffi/model.py
@@ -264,9 +264,10 @@ class PointerType(BaseType):
def __init__(self, totype, quals=0):
self.totype = totype
self.quals = quals
- extra = qualify(quals, " *&")
+ extra = " *&"
if totype.is_array_type:
extra = "(%s)" % (extra.lstrip(),)
+ extra = qualify(quals, extra)
self.c_name_with_marker = totype.c_name_with_marker.replace('&', extra)
def build_backend_type(self, ffi, finishlist):