From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andy Wingo Newsgroups: gmane.lisp.guile.devel Subject: Re: When to use SCM_DEFINE vs SCM_GPROC vs SCM_PRIMITIVE_GENERIC? Date: Sat, 29 Jan 2011 18:17:04 +0100 Message-ID: References: <87sjwb3eik.fsf@yeeloong.netris.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1296321141 32418 80.91.229.12 (29 Jan 2011 17:12:21 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sat, 29 Jan 2011 17:12:21 +0000 (UTC) Cc: guile-devel@gnu.org To: Mark H Weaver Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Sat Jan 29 18:12:16 2011 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PjELO-0002qo-Jv for guile-devel@m.gmane.org; Sat, 29 Jan 2011 18:12:14 +0100 Original-Received: from localhost ([127.0.0.1]:57687 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PjELN-00053V-T3 for guile-devel@m.gmane.org; Sat, 29 Jan 2011 12:12:13 -0500 Original-Received: from [140.186.70.92] (port=34079 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PjELJ-00050w-U9 for guile-devel@gnu.org; Sat, 29 Jan 2011 12:12:10 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PjELI-0007RB-FE for guile-devel@gnu.org; Sat, 29 Jan 2011 12:12:09 -0500 Original-Received: from a-pb-sasl-sd.pobox.com ([64.74.157.62]:34760 helo=sasl.smtp.pobox.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PjELI-0007R2-Cu for guile-devel@gnu.org; Sat, 29 Jan 2011 12:12:08 -0500 Original-Received: from sasl.smtp.pobox.com (unknown [127.0.0.1]) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTP id 3AB693F7A; Sat, 29 Jan 2011 12:12:59 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; s=sasl; bh=MepQm+W5ldrTR91CP4cK1P9N7Q8=; b=hObBbO y40UApnWcYQ0etcM18eYH7CjjTlG8NP6jmT6JdOJtJxCplsSmP755YQ4CnblFxvD J1168l98jxTfv6P8gjxuvKkTUCAcXzI3ETsJPKfMe7KkgKAYkQFu1RsOHFE0Cvde N89Pp9pyY4NdQ/PkT8uJO10CLJa9IbmINGfN0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; q=dns; s=sasl; b=lxxRPOGxYyTZA7p7AWX1HAjlre4c7KOl 9v4p031amHB+Exdek9AKqAaB9guk3ihZw9F8nDmzATVPhpn0T3BpJLWLYYeC7qHL XmSXNfCIzchC+9vb0clYKWUyZQiqJq4dcn6uf5Hbn4vSe5KmhXX2GlFXFHgJJ/YE 5xKD2UHsXQ4= Original-Received: from a-pb-sasl-sd.pobox.com (unknown [127.0.0.1]) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTP id 0878D3F79; Sat, 29 Jan 2011 12:12:58 -0500 (EST) Original-Received: from unquote.localdomain (unknown [90.164.198.39]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTPSA id 65A033F77; Sat, 29 Jan 2011 12:12:56 -0500 (EST) In-Reply-To: <87sjwb3eik.fsf@yeeloong.netris.org> (Mark H. Weaver's message of "Sat, 29 Jan 2011 10:39:47 -0500") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) X-Pobox-Relay-ID: 04CC400C-2BCB-11E0-A3E6-BC4EF3E828EC-02397024!a-pb-sasl-sd.pobox.com X-detected-operating-system: by eggs.gnu.org: Solaris 10 (beta) X-Received-From: 64.74.157.62 X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.devel:11401 Archived-At: On Sat 29 Jan 2011 16:39, Mark H Weaver writes: > Andy Wingo writes: >> And I don't recall the practical difference between GPROC and >> PRIMITIVE_GENERIC. > > I found the answer. According to a commit message by Mikael Djurfeldt > in 2003, all uses of SCM_GPROC should be converted to use > SCM_PRIMITIVE_GENERIC. > > http://blog.gmane.org/gmane.lisp.guile.cvs/month=20030301 > > I will do this for all extensible functions in numbers.c. I will also > make some other numeric functions extensible. For example, it occurs to > me if we make `inf?', `nan?', and `finite?' extensible, then users will > be able to easily extend them to handle non-real complex values, if > desired. Sounds great to me. Thanks for doing the archeology! Andy -- http://wingolog.org/