Matthew Brush
2013-08-18 00:40:32 UTC
Hi Neil,
Is there a minimum version of Glib that Scintilla supports? I mean if
one wanted to use something from say v2.30, would one have to guard out
the code using version checking macros? What if it meant not compiling a
file on certain version?
The reason I ask is that currently Scintilla has undefined behaviour in
this (generated) file here:
https://sourceforge.net/p/scintilla/code/ci/default/tree/gtk/scintilla-marshal.c#l78
And Geany also has same UB (elsewhere) due to using marshaller like this
(casting void* to function ptr). I would like to fix this (in both
projects, if you'd like a patch), but the change here:
https://git.gnome.org/browse/glib/commit/?id=88ab35f3cb6127036361e421987a127bddb989c8
Which, if I understand correctly, allows setting the c_marshaller
function to NULL in g_signal_new*() and uses libffi instead to deal with
this, is not available until GLib v2.30.
Please advise, or say whether you'd even want such a change. The UB is
really quite pedantic and is actually defined behaviour on POSIX
platforms AFAICT (see dlsym() docs), just not ISO C (and so causes
compiler warnings with strict/pedantic enough flags).
As data points, my Ubuntu 13.04 computer has GLib v2.36 and I think
Geany supports as far back as v2.20.
Cheers,
Matthew Brush
Is there a minimum version of Glib that Scintilla supports? I mean if
one wanted to use something from say v2.30, would one have to guard out
the code using version checking macros? What if it meant not compiling a
file on certain version?
The reason I ask is that currently Scintilla has undefined behaviour in
this (generated) file here:
https://sourceforge.net/p/scintilla/code/ci/default/tree/gtk/scintilla-marshal.c#l78
And Geany also has same UB (elsewhere) due to using marshaller like this
(casting void* to function ptr). I would like to fix this (in both
projects, if you'd like a patch), but the change here:
https://git.gnome.org/browse/glib/commit/?id=88ab35f3cb6127036361e421987a127bddb989c8
Which, if I understand correctly, allows setting the c_marshaller
function to NULL in g_signal_new*() and uses libffi instead to deal with
this, is not available until GLib v2.30.
Please advise, or say whether you'd even want such a change. The UB is
really quite pedantic and is actually defined behaviour on POSIX
platforms AFAICT (see dlsym() docs), just not ISO C (and so causes
compiler warnings with strict/pedantic enough flags).
As data points, my Ubuntu 13.04 computer has GLib v2.36 and I think
Geany supports as far back as v2.20.
Cheers,
Matthew Brush
--
You received this message because you are subscribed to the Google Groups "scintilla-interest" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scintilla-interest+***@googlegroups.com.
To post to this group, send email to scintilla-***@googlegroups.com.
Visit this group at http://groups.google.com/group/scintilla-interest.
For more options, visit https://groups.google.com/groups/opt_out.
You received this message because you are subscribed to the Google Groups "scintilla-interest" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scintilla-interest+***@googlegroups.com.
To post to this group, send email to scintilla-***@googlegroups.com.
Visit this group at http://groups.google.com/group/scintilla-interest.
For more options, visit https://groups.google.com/groups/opt_out.