From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Nala Ginrut Newsgroups: gmane.lisp.guile.devel Subject: What's the plan about language-joiner? Date: Sat, 08 Dec 2012 23:47:27 +0800 Organization: HFG Message-ID: <1354981647.22533.45.camel@Renee-desktop.suse> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1354981667 10580 80.91.229.3 (8 Dec 2012 15:47:47 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 8 Dec 2012 15:47:47 +0000 (UTC) To: guile-devel@gnu.org Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Sat Dec 08 16:47:58 2012 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ThMdA-0001SC-5K for guile-devel@m.gmane.org; Sat, 08 Dec 2012 16:47:56 +0100 Original-Received: from localhost ([::1]:60094 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ThMcx-00040M-SC for guile-devel@m.gmane.org; Sat, 08 Dec 2012 10:47:43 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:46265) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ThMcv-00040F-EM for guile-devel@gnu.org; Sat, 08 Dec 2012 10:47:42 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ThMcs-0005FD-FZ for guile-devel@gnu.org; Sat, 08 Dec 2012 10:47:41 -0500 Original-Received: from mail-pb0-f41.google.com ([209.85.160.41]:54165) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ThMcs-0005F6-8J for guile-devel@gnu.org; Sat, 08 Dec 2012 10:47:38 -0500 Original-Received: by mail-pb0-f41.google.com with SMTP id xa7so980451pbc.0 for ; Sat, 08 Dec 2012 07:47:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:subject:from:to:date:organization:content-type:x-mailer :mime-version:content-transfer-encoding; bh=QHRU2ngmqhdCFDfBNnmFzCQfXzVoOOLdaggcsBaTGhI=; b=jGpOxTaxBhbpdidqweajBEPAo5OVfnagjCrFkLZNjTdmxX/cRzPnArd0Rlx+3T9iOB s7NSRpEhbJ9WBFWllDZ/C1DSmKVE0uVoSbdcZAMOhYE/DZY8bx6I8XZFk2RFfcdjqDwH xBfvWyJCoSaXWJMfbvI6ytago9OxCCuN/+Y+pHl23vFT+mNS9ckMwpUwSY9hKakB73c+ WGTQnhqpcg/OHZv0XD9QFvyQjlEOTM9w3gLIG7O3PKOrbx6r2Co5iluvG36CF6dmvi22 Eyne6BMXOSZ+/AkVOMHPh6Jg0l4WSunN27M3mraXzoznJhimatYOGyz8TUOSUuGA4zhD YqZQ== Original-Received: by 10.66.87.42 with SMTP id u10mr21702561paz.62.1354981656635; Sat, 08 Dec 2012 07:47:36 -0800 (PST) Original-Received: from [192.168.100.103] ([59.40.201.64]) by mx.google.com with ESMTPS id z5sm5517022pax.9.2012.12.08.07.47.32 (version=SSLv3 cipher=OTHER); Sat, 08 Dec 2012 07:47:35 -0800 (PST) X-Mailer: Evolution 3.4.4 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-Received-From: 209.85.160.41 X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Original-Sender: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.devel:15315 Archived-At: Test code here: ------------------------cut-------------------------- # echo "(+ 1 1)" > aa.scm # guild compile aa.scm --from=scheme --to=glil -o aa.glil # guild compile aa.glil --from=glil --to=assembly -o aa.asm ------------------------end-------------------------- Error throws: "don't know how to join expressions" And I checked the code, the problem is in "read-and-compile" in module/system/base/compile.scm. It tries to get "language-joiner", but only 'tree-il' has "joiner". That means, if I try to compile any intermediate-language lower than 'tree-il', it'll throw the error message. IMO, we ought to let guild compile any intermediate-language to any lower level. And I can do such job follow these steps: 1. read out "aa.glil" 2. parser-glil the glil code 3. (compile glil-code #:from 'glil #:to 'assembly) But I can't do it with 'guild compile' since it calls "read-and-compile", which needs the weird "language-joiner". There's no any docs for 'language-joiner' in the manual. Here're the questions: 1. So what's the plan about 'language-joiner'? 2. What's the utility? 3. Why only 'tree-il' has it? 4. What about implementing 'joiner' for other lower ILs? Thanks!