Re: mmap for guile

2022-07-19 Thread Maxime Devos
Ludovic Courtès schreef op ma 04-07-2022 om 12:09 [+0200]: > I don’t think the optimizer makes any such assumption, except for > literal bytevectors. It _does_ assume that bytevector lengths don't change: ,use (rnrs bytevectors) ,compile (bytevector-u8-ref some-variable 999) ;;; : warning: possi

Re: mmap for guile

2022-07-19 Thread Maxime Devos
Ludovic Courtès schreef op ma 04-07-2022 om 12:09 [+0200]: > But we could provide special semantics: the bytevector would become > zero-length (possible, but weird, as Maxime points out), or it would > be turned into a /dev/zero mapping (weird as well). > > Thoughts? The former is weird and can c

Re: mmap for guile

2022-07-19 Thread Maxime Devos
Ludovic Courtès schreef op ma 04-07-2022 om 12:09 [+0200]: > > Also, what if you mmap a region, use bytevector->pointer and pass > > it to > > some C thing, which saves the pointer somewhere where boehm-gc can > > find > > it and boehm-gc considers it to be live, is there something that > > prevent

Re: Contracts macro example

2022-07-19 Thread Maxime Devos
Zelphir Kaltstahl schreef op do 14-07-2022 om 23:55 [+]: >   (make-assertion-failure) >   (make-exception-with-message "assertion failed") >   (make-exception-with-irritants (quote (op args* ...)] Instead of a generic 'assertion failure', I believe a more specific &

G-Golf - how to access gtk APIS that take lists of arguments ending with null ptr

2022-07-19 Thread Andy Tai
How to call gtk APIs such as (gtk+ 3) gint gtk_tree_view_insert_column_with_attributes (GtkTreeView *tree_view, gint position, const gchar *title, GtkCellRenderer *cell,

Re: G-Golf - how to access gtk APIS that take lists of arguments ending with null ptr

2022-07-19 Thread David Pirotte
Hello, > How to call gtk APIs such as > (gtk+ 3) > gint > gtk_tree_view_insert_column_with_attributes >(GtkTreeView *tree_view, > gint position, > const gchar *title, >