From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: =?UTF-8?Q?Linus_Bj=C3=B6rnstam?= Newsgroups: gmane.lisp.guile.user Subject: Re: Happy birthday, Guile! Date: Sun, 16 Feb 2020 17:20:48 +0100 Message-ID: <4ec25ad7-282d-4948-979e-93315faf4237@www.fastmail.com> References: <874kvq1syo.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain;charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="120716"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Cyrus-JMAP/3.1.7-802-g7a41c81-fmstable-20200203v1 To: guile-user@gnu.org Original-X-From: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Sun Feb 16 17:21:40 2020 Return-path: Envelope-to: guile-user@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1j3Mfq-000V4s-Mu for guile-user@m.gmane-mx.org; Sun, 16 Feb 2020 17:21:39 +0100 Original-Received: from localhost ([::1]:33798 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j3Mfp-0006YE-CP for guile-user@m.gmane-mx.org; Sun, 16 Feb 2020 11:21:37 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:44055) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j3MfT-0006VN-RX for guile-user@gnu.org; Sun, 16 Feb 2020 11:21:17 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j3MfQ-0001gG-IX for guile-user@gnu.org; Sun, 16 Feb 2020 11:21:15 -0500 Original-Received: from wout2-smtp.messagingengine.com ([64.147.123.25]:42193) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1j3MfQ-0001cr-7t for guile-user@gnu.org; Sun, 16 Feb 2020 11:21:12 -0500 Original-Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.west.internal (Postfix) with ESMTP id AE9665ED for ; Sun, 16 Feb 2020 11:21:09 -0500 (EST) Original-Received: from imap1 ([10.202.2.51]) by compute1.internal (MEProxy); Sun, 16 Feb 2020 11:21:09 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.se; h= mime-version:message-id:in-reply-to:references:date:from:to :subject:content-type:content-transfer-encoding; s=fm2; bh=uoqYo llbP5VEDXEogWoK356N/UnlhgJO7y5eG4IRnMY=; b=xk/9C98OLRReqH0YsyNMa 4Do2J6huZTjLqzeIjvDkDGujCaPAGkvCt9O4tY7Sx/6DQG9PfmpBS1rjFo5Ow7H2 jSryBGLnuvOS6/NQWB0jUtZbbm3M6guZxdNzr1HUjF1SKPgnxahhszzg4xQ8Vtc3 FfZYEjV7tGjNMlpSyOFqGoSt7SxeRQPfqLv7bUK1k/7P+fVsJPhRU02GfdS28a5e bDlYgoGG+xRy04vUc7ieiOw8vhSd6EVqpcIbYxYsloOKoFd4+gwznOOnKA3SDqkU Q451E16Oi8rsXHdn6jBp4idZa8L8plwoIo0dswNA3AUx5cwvaevNx+NoF6138awM g== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=uoqYollbP5VEDXEogWoK356N/UnlhgJO7y5eG4IRn MY=; b=r757CHGyNknkbWLpsWunN+y6oUGuEcz6e8sR7dHjIILXiUtDYyZsgP1rO UYvz0XtBK33rKUOFMuuHIdpGbNO8qea/vCvsdshZl726uanwh1f1sr2Itr978mQ0 pwNtpfcKdFIm0Vko8XRZCcD5z/rs1MNOLwrNlwdDgdKSWzqMs2GJL1U1ZVNTFZPh XG6cXuus4Bm44H997Cy+9A1oWQGxJuK7RtVHEqIiXjIMdZkOVYxVqEsvqaMrZMvG 1QswdFE8oFuQTxIfoaBITd0EBGR+0XN8pwzqwAKxEJTRL0SN9DMjrTYAkjaM5SD2 8M09O/cB+Ok2SadTFQrfiFZdoAfaQ== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedugedrjeeggdekiecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecunecujfgurhepofgfggfkjghffffhvffutgfgsehtqh ertderreejnecuhfhrohhmpefnihhnuhhspgeujhpnrhhnshhtrghmuceolhhinhhushdr ihhnthgvrhhnvghtsehfrghsthhmrghilhdrshgvqeenucffohhmrghinhepshhrrdhhth dpghhnuhdrohhrghenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhl fhhrohhmpehlihhnuhhsrdhinhhtvghrnhgvthesfhgrshhtmhgrihhlrdhsvg X-ME-Proxy: Original-Received: by mailuser.nyi.internal (Postfix, from userid 501) id 08EACC200A4; Sun, 16 Feb 2020 11:21:09 -0500 (EST) X-Mailer: MessagingEngine.com Webmail Interface In-Reply-To: <874kvq1syo.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 64.147.123.25 X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.23 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-mx.org@gnu.org Original-Sender: "guile-user" Xref: news.gmane.io gmane.lisp.guile.user:16184 Archived-At: Hooray! I have a bunch of small utils that I use to make repl life easie= r. One thing I did to scratch an itch is a clojuresque lambda shorthand = (cut on steroids) for guile. It transverses whatever expressions you put= into it and rewrites it into a lambda where all identifiers of the form= %n where n is an integer gets transformed into a lambda argument. https://hg.sr.ht/~bjoli/megacut/browse (megacut (let ((a "Hello ")) (string-append a %1))) =3D> (lambda (%1) (let ((a "Hello")) (string-append a %1))) Using read-hash-extend one can write #%: #%(apply + (/ 10 %1) %&) =3D> (lambda (%1 . %&) (apply + (/ 10 %1) %&)) It supports arbitrary many arguments, and also allows for "ignoring" arg= uments:=20 #%(display %3) =3D> (lambda (%1 %2 %3) (display %3)) A regular % is also a shorthand for %1: #%(+ % %) =3D> (lambda (%1) (+ %1 %1)) I use it daily. 20 minutes of scripting that the last year or so probabl= y saves me at least 25 seconds of typing :) It has rudimentary unhygienic support for nesting, which may or may not = be a terrible idea. I have another useful little function, port->list which takes a port and= a read function and returns a list of whatever the reader function retu= rns until the port EOFs. less powerful than port-fold, but less fuss to = use when you just want a list. I leave that as an exercise for the reade= r, though. --=20 Linus Bj=C3=B6rnstam On Sun, 16 Feb 2020, at 15:56, Ludovic Court=C3=A8s wrote: > Hello Guilers! >=20 > Today, it=E2=80=99s been 9 years since Guile 2.0 came out! >=20 > https://lists.gnu.org/archive/html/guile-devel/2011-02/msg00173.html= >=20 > It=E2=80=99s impressive how much has been accomplished since 2.0, and = how what > seemed like a pipe dream back then came into reality with 3.0. I thin= k > Guile 2.0 started a renaissance of Guile, and it=E2=80=99s in bloom no= w. :-) >=20 > We used to have a =E2=80=9CGuile potluck=E2=80=9D for the anniversary,= where people > would bring their own hacks and virtually join for a party. We missed= > it this year, but if there=E2=80=99s a nice hack that you=E2=80=99d li= ke to share, now > is a good time! >=20 > Happy hacking with Guile! >=20 > Ludo=E2=80=99. >=20 > Attachments: > * signature.asc