Fix compilation of `numbers.c' with Sun CC.
[bpt/guile.git] / libguile / ChangeLog
index d7e1ced..7bcb196 100644 (file)
@@ -1,3 +1,196 @@
+2008-02-06  Ludovic Courtès  <ludo@gnu.org>
+
+       * numbers.c (scm_i_mkbig, scm_i_long2big, scm_i_ulong2big,
+       scm_i_clonebig, scm_i_bigcmp, scm_i_dbl2big, scm_i_dbl2num,
+       scm_i_normbig): Remove `SCM_C_INLINE_KEYWORD' since these are
+       declared as `extern' in `numbers.h'.  This precluded compilation
+       on Solaris 9 with Sun CC (reported by David Halik
+       <dhalik@nbcs.rutgers.edu>).
+
+2008-02-05  Neil Jerram  <neil@ossau.uklinux.net>
+
+       * fports.c (fport_seek): Make dependent on GUILE_USE_64_CALLS.
+
+       * _scm.h: Make definition of CHOOSE_LARGEFILE depend on
+       GUILE_USE_64_CALLS.
+
+2008-02-01  Neil Jerram  <neil@ossau.uklinux.net>
+
+       * modules.c (the_root_module): Moved before scm_current_module.
+       (scm_current_module): Return the root module if `the-module' fluid
+       gives #f.
+
+2008-01-22  Neil Jerram  <neil@ossau.uklinux.net>
+
+       * COPYING: Removed.
+
+       * __scm.h, _scm.h, weaks.c: Update copyright statement to LGPL.
+
+2008-01-18  Neil Jerram  <neil@ossau.uklinux.net>
+
+       * hashtab.c (scm_hash_fn_create_handle_x): If supplied assoc_fn
+       returns neither a pair nor #f, signal a wrong-type-arg error.
+       (Thanks to Gregory Marton for reporting this.)
+
+2007-12-29  Neil Jerram  <neil@ossau.uklinux.net>
+
+       * gc.c (mark_gc_async): Change "func_data" to "fn_data", to avoid
+       clash with AIX header file.
+       * hooks.c (scm_c_hook_add, scm_c_hook_remove): Same again.
+       * hooks.h (scm_t_c_hook_function, scm_c_hook_add,
+       scm_c_hook_remove): Same again.
+
+2007-12-08  Ludovic Courtès  <ludo@gnu.org>
+
+       * __scm.h (SCM_EXPECT, SCM_LIKELY, SCM_UNLIKELY): New macros.
+       (SCM_ASSERT, SCM_ASSERT_TYPE, SCM_ASRTGO, SCM_GASSERT0,
+       SCM_GASSERT1, SCM_GASSERT2, SCM_GASSERTn): Use them.
+       * eval.c (ASSERT_SYNTAX, ASSERT_SYNTAX_2): Likewise.
+       * eval.i.c (CEVAL): Use branch prediction hints for syntax
+       errors, wrong number of arguments and similar.
+       * numbers.c (scm_sum): Use `SCM_LIKELY' for the sum of two
+       immediate numbers.
+       (scm_difference, scm_product, scm_i_divide): Likewise.
+       * validate.h (SCM_ASSERT_RANGE): Use `SCM_UNLIKELY'.
+
+2007-12-04  Ludovic Courtès  <ludo@gnu.org>
+
+       * ports.c (scm_c_read): Validate PORT as an open input port.
+       (scm_c_write): Validate PORT as an open output port.
+
+       * socket.c (scm_accept): Leave guile mode using
+       `scm_std_select ()' before calling `accept(2)'.  Reported by
+       dskr <dskr@mac.com>.
+
+2007-10-27  Ludovic Courtès  <ludo@gnu.org>
+
+       * fports.c (scm_i_evict_port): Expect a port, rather than a pair
+       containing the port.  Fixes a bug in the new port table (2007-08-26).
+       (scm_evict_ports): Use `scm_c_port_for_each ()'.
+
+2007-10-21  Neil Jerram  <neil@ossau.uklinux.net>
+
+       * eval.c (unmemoize_delay): Extend the environment before
+       unmemoizing the promise thunk.  This fixes a segmentation fault
+       reported by Frank Schwidom.
+
+2007-10-20  Julian Graham  <joolean@gmail.com>
+
+       Add support for thread cancellation and user-defined thread
+       cleanup handlers.  Small rework by Ludovic Courtès.
+
+       * null-threads.h (scm_i_pthread_cancel,
+       scm_i_pthread_cleanup_push, scm_i_pthread_cleanup_pop): New.
+       * pthread-threads.h (scm_i_pthread_cancel,
+       scm_i_pthread_cleanup_push, scm_i_pthread_cleanup_pop): New.
+       * scmsigs.c (scm_i_signal_delivery_thread,
+       signal_delivery_thread_mutex): New.
+       (signal_delivery_thread): Leave when `read_without_guile ()'
+       returns zero.
+       (start_signal_delivery_thread): Acquire SIGNAL_DELIVERY_THREAD
+       before spawning the thread.  Initialize
+       SCM_I_SIGNAL_DELIVERY_THREAD.
+       (ensure_signal_delivery_thread): Renamed to...
+       (scm_i_ensure_signal_delivery_thread): this.
+       (scm_i_close_signal_pipe): New.
+       * scmsigs.h: Updated.
+       * threads.c (thread_mark): Mark `t->cleanup_handler'.
+       (guilify_self_1): Initialize `t->cleanup_handler' and
+       `t->canceled'.
+       (do_thread_exit): Invoke `t->cleanup_handler'.
+       (on_thread_exit): Call `scm_i_ensure_signal_delivery_thread ()'.
+       Call `scm_i_close_signal_pipe ()' when the next-to-last thread
+       vanishes.
+       (scm_leave_guile_cleanup): New.
+       (scm_i_with_guile_and_parent): Use `scm_i_pthread_cleanup_push ()' 
+       and `scm_leave_guile_cleanup ()' to leave guile mode, rather
+       than call `scm_leave_guile ()' after FUNC.
+       (scm_cancel_thread, scm_set_thread_cleanup_x,
+       scm_threads_cleanup): New.
+       (scm_all_threads): Remove SCM_I_SIGNAL_DELIVERY_THREAD from the
+       returned list.
+       * threads.h (scm_i_thread)[cleanup_handler, canceled]: New
+       fields.
+       Add declarations of new functions.
+       
+2007-10-17  Ludovic Courtès  <ludo@gnu.org>
+
+       * read.c (CHAR_IS_BLANK_): Add `\r' (ASCII 0x0d).  This fixes a
+       regression compared to 1.8.2.  Reported by Puneet
+       <schemer@gmail.com>.
+
+2007-10-10  Ludovic Courtès  <ludo@gnu.org>
+
+       * pthread-threads.h (SCM_I_PTHREAD_MUTEX_INITIALIZER): Check
+       `SCM_NEED_BRACES_ON_PTHREAD_MUTEX_INITIALIZER'.
+       * gen-scmconfig.h.in
+       (SCM_I_GSC_NEED_BRACES_ON_PTHREAD_MUTEX_INITIALIZER): New.
+       * gen-scmconfig.c (main): Define
+       `SCM_NEED_BRACES_ON_PTHREAD_MUTEX_INITIALIZER'.
+
+2007-10-04  Ludovic Courtès  <ludo@gnu.org>
+
+       * i18n.c (scm_make_locale)[!USE_GNU_LOCALE_API]: Don't call
+       `leave_locale_section ()' on failure of
+       `enter_locale_section ()' since the mutex is not held and locale
+       settings are unchanged.
+       (scm_nl_langinfo)[!USE_GNU_LOCALE_API]: Use
+       `restore_locale_settings ()' instead of `leave_locale_section ()' 
+       since the mutex is not held.
+       
+2007-10-02  Ludovic Courtès  <ludo@gnu.org>
+
+       * threads.c (on_thread_exit): Don't call `scm_leave_guile ()'
+       since we're already in non-guile mode.  Reported by Greg Toxel
+       for NetBSD.
+
+2007-10-01  Ludovic Courtès  <ludo@gnu.org>
+
+       * ports.c (flush_output_port): Expect directly a port instead of
+       a pair.  Fixes a bug in the new port table (2007-08-26).
+
+2007-09-11  Kevin Ryde  <user42@zip.com.au>
+
+       * posix.c (scm_putenv): Confine the putenv("NAME=") bit to mingw, use
+       putenv("NAME") as the fallback everywhere else.  In particular this is
+       needed for solaris 9.  Reported by Frank Storbeck.
+       
+2007-09-03  Ludovic Courtès  <ludo@gnu.org>
+
+       * read.c (flush_ws): Handle SCSH block comments.
+
+2007-09-03  Ludovic Courtès  <ludo@gnu.org>
+
+       Fix alignment issues which showed up at least on SPARC.
+
+       * socket.c (scm_t_max_sockaddr, scm_t_getsockopt_result): New.
+       (scm_inet_pton): Change DST to `scm_t_uint32' for correct
+       alignment.
+       (scm_getsockopt): Change OPTVAL to `scm_t_getsockopt_result' for
+       correct alignment.
+       (_scm_from_sockaddr): Change ADDRESS to `scm_t_max_sockaddr *'.
+       (scm_from_sockaddr): Cast ADDRESS to `scm_t_max_sockaddr *'.
+       (MAX_SIZE_UN, MAX_SIZE_IN6): Removed.
+       (scm_accept, scm_getsockname, scm_getpeername, scm_recvfrom):
+       Use `scm_t_max_sockaddr' instead of "char max_addr[MAX_ADDR_SIZE]".
+
+2007-09-03  Kevin Ryde  <user42@zip.com.au>
+
+       * numbers.c (scm_log): Test HAVE_CLOG as well as HAVE_COMPLEX_DOUBLE
+       before using clog().  It's possible for gcc to provide the "complex
+       double" type, but for the system not to have the complex funcs.
+       (scm_exp): Ditto HAVE_CEXP for cexp().
+       (clog, cexp, carg): Remove fallback definitions.  These only
+       duplicated the code within scm_log and scm_exp, and the latter have to
+       exist for the case when there's no "complex double".  So better just
+       fix up the conditionals selecting between the complex funcs and plain
+       doubles than worry about fallbacks.
+
+2007-09-02  Ludovic Courtès  <ludo@gnu.org>
+
+       * socket.c (scm_make_socket_address): Free C_ADDRESS after use.
+       This fixes a memory leak.
+
 2007-08-26  Han-Wen Nienhuys  <hanwen@lilypond.org>
 
        * fports.c gc-card.c gc.c gc.h ioext.c ports.c ports.h weaks.h
 2007-08-23  Ludovic Courtès  <ludo@gnu.org>
 
        * read.c (scm_read_quote): Record position and copy source
-       expression when asked to.  Reported by Kevin Ryde.
+       expression when asked to.  Reported by Kevin.
 
        * stime.c: Define `_REENTRANT' only if not already defined.