From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8350 invoked by alias); 28 Jan 2017 23:08:14 -0000 Mailing-List: contact kawa-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: kawa-owner@sourceware.org Received: (qmail 8340 invoked by uid 89); 28 Jan 2017 23:08:13 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.5 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 spammy=dotted, Hx-languages-length:1637, Kawa X-HELO: aibo.runbox.com Received: from aibo.runbox.com (HELO aibo.runbox.com) (91.220.196.211) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sat, 28 Jan 2017 23:08:03 +0000 Received: from [10.9.9.212] (helo=mailfront12.runbox.com) by mailtransmit02.runbox with esmtp (Exim 4.86_2) (envelope-from ) id 1cXc6B-0006gx-RY; Sun, 29 Jan 2017 00:07:59 +0100 Received: from 70-36-239-8.dsl.dynamic.fusionbroadband.com ([70.36.239.8] helo=localhost.localdomain) by mailfront12.runbox.com with esmtpsa (uid:757155 ) (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.82) id 1cXc68-0000Z0-Nz; Sun, 29 Jan 2017 00:07:56 +0100 Subject: Re: Missing feature or just differences with Guile for define-public To: scprotz , kawa@sourceware.org References: From: Per Bothner Message-ID: Date: Sat, 28 Jan 2017 23:08:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2017-q1/txt/msg00038.txt.bz2 On 01/28/2017 04:40 AM, scprotz wrote: > I was trying to compile the scm files that come with Aisleriot using > Kawa (these are intended for use with Guile, but I was hoping to try > them out in Java). Many seem to compile ok, but one of the core > files, api.scm has problems. > > I came across two issues when trying to convert api.scm to .class. > > The first was "invalid use of '_". Apparently kawa doesn't like the _ > as part of define's. Easy enough to fix just by changing the '_ to > another identifier. > > The second issue though was I get "improper list (circular or dotted) > is not allowed here. > > Here is an example define-public from the file: > > (define-public (set-features . feature-list) > (set-feature-word! (+ (get-feature-word) > (apply + feature-list)))) > > My scheme-fu is very very weak, so I'm not sure if this is just an > implementation difference, a bug, or my misunderstanding. This problem is because Kawa does not define define-public, so Kawa thinks it is a function call. And an quoted dotted list is not valid in an expression. Kawa has a different module system that Guile. Specifically, it does not define define-module, use-module, or define-public. It might be possible to define Kawa implementations for the Guile module system on top of the Kawa module system, though there would probably be some incompatibilities. It seems like Aisleriot depends on lots of native code, including calls to Gnome. So getting anything working will be a major porting effort. -- --Per Bothner per@bothner.com http://per.bothner.com/