After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 705602 - scanner: Strip trailing * for element type of flat arrays
scanner: Strip trailing * for element type of flat arrays
Status: RESOLVED OBSOLETE
Product: gobject-introspection
Classification: Platform
Component: g-ir-scanner
unspecified
Other All
: Normal normal
: ---
Assigned To: gobject-introspection Maintainer(s)
gobject-introspection Maintainer(s)
Depends on:
Blocks: 704842
 
 
Reported: 2013-08-07 09:35 UTC by Colin Walters
Modified: 2018-02-08 12:23 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
scanner: Strip trailing * for element type of flat arrays (9.58 KB, patch)
2013-08-07 09:35 UTC, Colin Walters
needs-work Details | Review
scanner: Strip trailing * for element type of flat arrays (9.53 KB, patch)
2013-08-07 09:42 UTC, Colin Walters
none Details | Review

Description Colin Walters 2013-08-07 09:35:36 UTC
Bindings that are handling output flat arrays differentiate
them by looking at "is_pointer".

See https://bugzilla.gnome.org/show_bug.cgi?id=704842
Comment 1 Colin Walters 2013-08-07 09:35:39 UTC
Created attachment 251040 [details] [review]
scanner: Strip trailing * for element type of flat arrays
Comment 2 Jasper St. Pierre (not reading bugmail) 2013-08-07 09:38:15 UTC
Review of attachment 251040 [details] [review]:

::: giscanner/maintransformer.py
@@ +356,3 @@
+        r = re.compile(r'[^*]\*$')
+        if element_type_node.ctype is not None and \
+           r.search(element_type_node.ctype) is not None:

element_type_node.endswith('*') ?
Comment 3 Colin Walters 2013-08-07 09:42:16 UTC
Created attachment 251041 [details] [review]
scanner: Strip trailing * for element type of flat arrays

Fix C tests code.
Comment 4 Colin Walters 2013-08-07 10:18:49 UTC
(In reply to comment #2)
> Review of attachment 251040 [details] [review]:
> 
> ::: giscanner/maintransformer.py
> @@ +356,3 @@
> +        r = re.compile(r'[^*]\*$')
> +        if element_type_node.ctype is not None and \
> +           r.search(element_type_node.ctype) is not None:
> 
> element_type_node.endswith('*') ?

That's not the same, because that would match **, which we don't want - we're trying to match flat arrays.
Comment 5 Colin Walters 2013-08-15 21:30:52 UTC
Jasper, can you look at this one again?
Comment 6 Jasper St. Pierre (not reading bugmail) 2014-01-08 23:33:51 UTC
Review of attachment 251041 [details] [review]:

::: giscanner/maintransformer.py
@@ +354,3 @@
 
+    def _maybe_strip_flat_ctype(self, element_type_node):
+        r = re.compile(r'[^*]\*$')

I'm skeptical of this, simply because it would fail on "foo_t * *". Do we normalize ctype names?
Comment 7 André Klapper 2015-02-07 17:11:08 UTC
[Mass-moving gobject-introspection tickets to its own Bugzilla product - see bug 708029. Mass-filter your bugmail for this message: introspection20150207 ]
Comment 8 GNOME Infrastructure Team 2018-02-08 12:23:27 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to GNOME's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/gobject-introspection/issues/90.