From 1b57fdd43a7b567d343d5369512fd5b5554e759e Mon Sep 17 00:00:00 2001 From: Ivan Maidanski Date: Wed, 17 Jan 2018 10:42:04 +0300 Subject: [PATCH] Add note of set_free_space_divisor, set_warn_proc ABI change after gc-7.1 Issue #197 (bdwgc). GC_set_free_space_divisor() and GC_set_warn_proc() used to return some value. But starting from version 7.1alpha2, these API functions do not return any value. * include/gc.h (GC_set_free_space_divisor, GC_set_warn_proc): Add comment that the setter used to returned the old value in gc-7.1 (and previous versions). --- include/gc.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/include/gc.h b/include/gc.h index 471f57fb..cfb0fd92 100644 --- a/include/gc.h +++ b/include/gc.h @@ -328,6 +328,8 @@ GC_API GC_ATTR_DEPRECATED GC_word GC_free_space_divisor; /* GC_call_with_alloc_lock() is required to */ /* avoid data races (if the value is modified */ /* after the GC is put to multi-threaded mode). */ + /* In version 7.1 (and before), the setter */ + /* returned the old value. */ GC_API void GC_CALL GC_set_free_space_divisor(GC_word); GC_API GC_word GC_CALL GC_get_free_space_divisor(void); @@ -1302,7 +1304,8 @@ GC_API int GC_CALL GC_invoke_finalizers(void); /* GC_set_warn_proc can be used to redirect or filter warning messages. */ /* p may not be a NULL pointer. msg is printf format string (arg must */ /* match the format). Both the setter and the getter acquire the GC */ -/* lock (to avoid data races). */ +/* lock (to avoid data races). In version 7.1 (and before), the setter */ +/* returned the old warn_proc value. */ typedef void (GC_CALLBACK * GC_warn_proc)(char * /* msg */, GC_word /* arg */); GC_API void GC_CALL GC_set_warn_proc(GC_warn_proc /* p */) GC_ATTR_NONNULL(1); -- 2.40.0