GNOME Bugzilla – Bug 794418
Missing nullable annotation on the return value of gio_volume_get_mount
Last modified: 2018-05-24 20:17:47 UTC
When calling gio's gio_volume_get_mount through the Haskell bindings haskell-gi, Haskell complained of receiving a null which it shouldn't, according to the introspection data. As garetxe described it on the haskell-gi bugtracker: > The issue was that the C function was returning NULL, but the introspection data said that that was not a possibility. In these cases haskell-gi checks anyway, and raises the exception you saw if NULL is returned when it is not expected. It cannot do much else, since it is not possible to build a valid Gio.Mount out of NULL. For nullable values, the right representation is Maybe Gio.Mount instead, with NULL -> Nothing. [1] https://github.com/haskell-gi/haskell-gi/issues/139 bug report for haskell-gi
Created attachment 369967 [details] [review] gio: Add missing (nullable) annotations to GDrive, GMount, GVolume Signed-off-by: Philip Withnall <withnall@endlessm.com>
-- 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/glib/issues/1354.