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: [PATCH 2/5] [mingw]: Have compiled-file-name produce valid names. Date: Sun, 01 May 2011 13:30:30 +0200 Message-ID: References: <1297784103-18322-1-git-send-email-janneke-list@xs4all.nl> <1297784103-18322-3-git-send-email-janneke-list@xs4all.nl> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1304251904 14076 80.91.229.12 (1 May 2011 12:11:44 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 1 May 2011 12:11:44 +0000 (UTC) Cc: Jan Nieuwenhuizen , guile-devel@gnu.org To: Noah Lavine Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Sun May 01 14:11:40 2011 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1QGVUx-0005We-9w for guile-devel@m.gmane.org; Sun, 01 May 2011 14:11:39 +0200 Original-Received: from localhost ([::1]:40624 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QGVUw-00060V-Iu for guile-devel@m.gmane.org; Sun, 01 May 2011 08:11:38 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:43283) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QGVUt-0005zk-7i for guile-devel@gnu.org; Sun, 01 May 2011 08:11:36 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QGVUq-0000nL-5y for guile-devel@gnu.org; Sun, 01 May 2011 08:11:35 -0400 Original-Received: from a-pb-sasl-sd.pobox.com ([64.74.157.62]:56333 helo=sasl.smtp.pobox.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QGVUq-0000nH-34 for guile-devel@gnu.org; Sun, 01 May 2011 08:11:32 -0400 Original-Received: from sasl.smtp.pobox.com (unknown [127.0.0.1]) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTP id 098D74BFB; Sun, 1 May 2011 08:13:33 -0400 (EDT) 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=ClzGAck4iCBYIJtDHJ79Wati9oc=; b=i/sKr3 9XXRWniE1stxXy6oMvIdEe+ACAAV8nlqIF8pwKksbZUckZk8hde6rl//WGyu7cOy kMblyks0NoeIuNEIChIckR8OUSCWfrhqTSSbUcJylavmfis+McqRFlSuCNxfmHMs ZK07dkmUHd4SCWWpAygRJdsqBWFeLeqYaJyYU= 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=XHK0wiTAj6iSZEy6h/pa4koTz5iNQNXJ c7ogjXkTh28aWRVgYHxc7BJNC4SSFwBEpr7NjAU7JSkYEiMnr5tM/u3O3moU3Fwk INI+39XaYNyujQAN4XtgX4EV0z242hraeByNnrueexGzj2CsaT194vUxr2pmgnn2 jTsei83itRY= 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 D99494BF9; Sun, 1 May 2011 08:13:29 -0400 (EDT) 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 C7B424BF7; Sun, 1 May 2011 08:13:26 -0400 (EDT) In-Reply-To: (Noah Lavine's message of "Fri, 29 Apr 2011 13:30:42 -0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) X-Pobox-Relay-ID: 6CEE06E8-73EC-11E0-871F-E8AB60295C12-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.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:12385 Archived-At: On Fri 29 Apr 2011 19:30, Noah Lavine writes: >> Is anyone interested in implementing a path library? > > I might be able to work on it. Super! > However, I don't know much about how Windows paths work. Are there any > special considerations beyond the directory separator? Yep! Check that racket web page I linked to. You don't have to implement all of it, but it should be possible to implement, given the path abstraction. > Also, are there any characters that are valid in filenames on some > systems but invalid on other systems? Ah, I see you are under the delusion that paths are composed of characters :) This is not the case. To the OS, paths are NUL-terminated byte arrays, with some constraints about their composition, but which are not necessarily representable as strings. It is nice to offer the ability to convert to and from strings, when that is possible, but we must not assume that it is indeed possible. Basically I think the plan should be to add scm_from_locale_path, scm_from_raw_path, etc to filesys.[ch], and change any pathname-accepting procedure in Guile to accept path objects, producing them from strings when given strings, and pass the bytevector representation to the raw o/s procedures like `open' et al. Then for a lot of the utilities, we can add (ice-9 paths) or something, and implement most of the utility functions in Scheme. Andy -- http://wingolog.org/