From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Linas Vepstas <linasvepstas@gmail.com> Newsgroups: gmane.lisp.guile.user Subject: Re: "unbound variable" Date: Mon, 27 Jun 2011 16:44:52 -0500 Message-ID: <BANLkTimC_ZW3i23ULszBsAEoOW7nM2tMLA@mail.gmail.com> References: <f9c627265c232612a94cb5ba324cc2d0.squirrel@webmail.xs4all.nl> <we1mr56fligt.fsf@ssclt001.ee.surrey.ac.uk> Reply-To: linasvepstas@gmail.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: dough.gmane.org 1309211142 334 80.91.229.12 (27 Jun 2011 21:45:42 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 27 Jun 2011 21:45:42 +0000 (UTC) Cc: guile-user@gnu.org To: Peter Brett <peter@peter-b.co.uk> Original-X-From: guile-user-bounces+guile-user=m.gmane.org@gnu.org Mon Jun 27 23:45:38 2011 Return-path: <guile-user-bounces+guile-user=m.gmane.org@gnu.org> Envelope-to: guile-user@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from <guile-user-bounces+guile-user=m.gmane.org@gnu.org>) id 1QbJcf-0002hm-7p for guile-user@m.gmane.org; Mon, 27 Jun 2011 23:45:37 +0200 Original-Received: from localhost ([::1]:42947 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from <guile-user-bounces+guile-user=m.gmane.org@gnu.org>) id 1QbJce-0003Na-3g for guile-user@m.gmane.org; Mon, 27 Jun 2011 17:45:36 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:56034) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from <linasvepstas@gmail.com>) id 1QbJcK-0003Mr-RU for guile-user@gnu.org; Mon, 27 Jun 2011 17:45:19 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from <linasvepstas@gmail.com>) id 1QbJcI-00049E-Fq for guile-user@gnu.org; Mon, 27 Jun 2011 17:45:16 -0400 Original-Received: from mail-fx0-f52.google.com ([209.85.161.52]:59521) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from <linasvepstas@gmail.com>) id 1QbJcI-00048q-07 for guile-user@gnu.org; Mon, 27 Jun 2011 17:45:14 -0400 Original-Received: by fxd18 with SMTP id 18so2017907fxd.39 for <guile-user@gnu.org>; Mon, 27 Jun 2011 14:45:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:reply-to:in-reply-to:references :from:date:message-id:subject:to:cc:content-type; bh=7PTAbowPSRDhIg8v1SIHEdWg0YNmNa3nuCnK/irae3Q=; b=t/6USTh3INUruvzumTA7ch4xSOGr3i3ZOwVSWFy2FfPLm2pJvNB2EPQSKf92TRfknP Qm7+zxrPFf9V5paDv/mvx9f5saQY3Kw0Mi/ge9dP3466J0JmduPOKhCiiyTeUyZpFrGI D6VStbqPnoV1v3iVNnxi0wlafqcZFQDRE4E5Y= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:reply-to:in-reply-to:references:from:date:message-id :subject:to:cc:content-type; b=WIp11LPUvoIIgfSZy+vD18Z/KtqOHn1Tss3IJKkA+KE/aQeXRprshC53jMRS9IFdpd zUAw0Cn3kFASiVKVTOk3I8X1DDwOi5GpvwmhOlxCv5/MZvcagBBjHiKkcXRB2W9cfe/6 kzGyXKKeUELP1Povot1JgxkVgtHJ/1VSXeTFY= Original-Received: by 10.223.159.197 with SMTP id k5mr9582257fax.50.1309211112085; Mon, 27 Jun 2011 14:45:12 -0700 (PDT) Original-Received: by 10.223.73.206 with HTTP; Mon, 27 Jun 2011 14:44:52 -0700 (PDT) In-Reply-To: <we1mr56fligt.fsf@ssclt001.ee.surrey.ac.uk> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 209.85.161.52 X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: General Guile related discussions <guile-user.gnu.org> List-Unsubscribe: <https://lists.gnu.org/mailman/options/guile-user>, <mailto:guile-user-request@gnu.org?subject=unsubscribe> List-Archive: </archive/html/guile-user> List-Post: <mailto:guile-user@gnu.org> List-Help: <mailto:guile-user-request@gnu.org?subject=help> List-Subscribe: <https://lists.gnu.org/mailman/listinfo/guile-user>, <mailto:guile-user-request@gnu.org?subject=subscribe> Errors-To: guile-user-bounces+guile-user=m.gmane.org@gnu.org Original-Sender: guile-user-bounces+guile-user=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.user:8667 Archived-At: <http://permalink.gmane.org/gmane.lisp.guile.user/8667> On 27 June 2011 04:41, Peter Brett <peter@peter-b.co.uk> wrote: > "Tomas By" <tomas@basun.net> writes: > >> I have an extended Guile interpreter with a C function "get-map", >> defined by "scm_c_define_gsubr", that I then try to use in the >> (pure Scheme) module "mapdisplay", with the following result: >> >> [snip] >> >> Any ideas what is happening here? How can I debug it? > > Having read the rest of this thread so far, I suggest that you put your > built-in functions into a module which can then be loaded by your pure > Scheme functions. Having used scm_c_define_gsubr in three different projects now, I'l disagree .. never had to create a module to use it ... Not sure what the bug is, though ... does get-map work if you don't use it within the module? Can you verify it works in some simple way? --linas