From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Marko Rauhamaa Newsgroups: gmane.lisp.guile.bugs Subject: Latent bugs? Date: 28 Dec 2002 00:49:39 -0800 Sender: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Message-ID: NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1041065667 18274 80.91.224.249 (28 Dec 2002 08:54:27 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Sat, 28 Dec 2002 08:54:27 +0000 (UTC) Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18SCji-0004kc-00 for ; Sat, 28 Dec 2002 09:54:26 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 18SCjz-0004s1-03 for guile-bugs@m.gmane.org; Sat, 28 Dec 2002 03:54:43 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10.13) id 18SCju-0004ns-00 for bug-guile@gnu.org; Sat, 28 Dec 2002 03:54:38 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10.13) id 18SCjr-0004lZ-00 for bug-guile@gnu.org; Sat, 28 Dec 2002 03:54:37 -0500 Original-Received: from [209.77.185.85] (helo=lumo.pacujo.net) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 18SCjr-0004jp-00 for bug-guile@gnu.org; Sat, 28 Dec 2002 03:54:35 -0500 Original-Received: (from marko@localhost) by lumo.pacujo.net (8.11.6/8.11.6/SuSE Linux 0.5) id gBS8ndJ19778; Sat, 28 Dec 2002 00:49:39 -0800 Original-To: bug-guile@gnu.org Original-Lines: 25 X-BeenThere: bug-guile@gnu.org X-Mailman-Version: 2.1b5 Precedence: list List-Id: Bug reports for GUILE, GNU's Ubiquitous Extension Language List-Help: List-Post: List-Subscribe: , List-Archive: List-Unsubscribe: , Errors-To: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Xref: main.gmane.org gmane.lisp.guile.bugs:602 X-Report-Spam: http://spam.gmane.org/gmane.lisp.guile.bugs:602 The Guile manual warns about "a Common Mistake in Allocating Smobs": http://www.gnu.org/software/guile/docs/guile-ref/A-Common-Mistake-In-Allocating-Smobs.html#A%20Common%20Mistake%20In%20Allocating%20Smobs Indeed, it seems to me the Guile 1.6.0 source code contains numerous instances of this common mistake. For example (in scmsigs.c): return scm_list_2(scm_cons(scm_long2num(old_timer.it_interval.tv_sec), scm_long2num(old_timer.it_interval.tv_usec)), scm_cons(scm_long2num(old_timer.it_value.tv_sec), scm_long2num(old_timer.it_value.tv_usec))); If I understand it correctly, this statement contains several allocations, each of which can potentially trigger garbage collection and delete any of the intermediate results. Have I mistaken? What is the right way of constructing and returning the list above? Marko -- Marko Rauhamaa mailto:marko@pacujo.net http://pacujo.net/marko/ _______________________________________________ Bug-guile mailing list Bug-guile@gnu.org http://mail.gnu.org/mailman/listinfo/bug-guile