From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Christopher Allan Webber Newsgroups: gmane.lisp.guile.user Subject: Named parameters to format? Date: Mon, 14 Dec 2015 22:52:35 -0600 Message-ID: <87egeo5mzl.fsf@dustycloud.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1450155378 28669 80.91.229.3 (15 Dec 2015 04:56:18 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 15 Dec 2015 04:56:18 +0000 (UTC) To: guile-user Original-X-From: guile-user-bounces+guile-user=m.gmane.org@gnu.org Tue Dec 15 05:56:18 2015 Return-path: Envelope-to: guile-user@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 1a8her-0005MP-6d for guile-user@m.gmane.org; Tue, 15 Dec 2015 05:56:17 +0100 Original-Received: from localhost ([::1]:35053 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a8heq-0001vM-Hm for guile-user@m.gmane.org; Mon, 14 Dec 2015 23:56:16 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:47417) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a8heh-0001vE-II for guile-user@gnu.org; Mon, 14 Dec 2015 23:56:08 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a8heg-0000T1-Gm for guile-user@gnu.org; Mon, 14 Dec 2015 23:56:07 -0500 Original-Received: from dustycloud.org ([2600:3c02::f03c:91ff:feae:cb51]:46348) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a8heg-0000Sr-C5 for guile-user@gnu.org; Mon, 14 Dec 2015 23:56:06 -0500 Original-Received: from earlgrey (localhost [127.0.0.1]) by dustycloud.org (Postfix) with ESMTPS id 2156426756 for ; Mon, 14 Dec 2015 23:56:05 -0500 (EST) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2600:3c02::f03c:91ff:feae:cb51 X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-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:12249 Archived-At: Hello all, I've been thinking about what I'm going to do once I hit the need for gettext support. I'm not really sure for things that have multiple variables in their string. In python land, I'd do something like: gettext("foo %(bar) %(baz)") % {"bar": "bleh", "baz": "wonk"} This would give translators an opportunity to move the right parameters to the right place in the string. However, this appears to not be possible in our current format system, because there's no place to put keyword based substitutable arguments. Syntactic word ordering varies from natural language to natural language, so... Surely someone's run into this before? What's the right solution? - Chris