From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50024) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ernpr-0001fe-LF for guix-patches@gnu.org; Fri, 02 Mar 2018 11:47:08 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ernpm-0000Oa-PR for guix-patches@gnu.org; Fri, 02 Mar 2018 11:47:07 -0500 Received: from debbugs.gnu.org ([208.118.235.43]:33572) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ernpm-0000OC-L4 for guix-patches@gnu.org; Fri, 02 Mar 2018 11:47:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ernpm-0005K3-3h for guix-patches@gnu.org; Fri, 02 Mar 2018 11:47:02 -0500 Subject: [bug#29483] [PATCH] services: Add openntpd service. Resent-Message-ID: From: ludo@gnu.org (Ludovic =?UTF-8?Q?Court=C3=A8s?=) References: <20171128090443.15544-1-efraim@flashner.co.il> <87lgimiwc2.fsf@gnu.org> <87k1wdh0eo.fsf@gnu.org> <20180129192423.GC17751@macbook41> <871shzbgoz.fsf@gnu.org> <20180302140211.GA3213@macbook41> Date: Fri, 02 Mar 2018 17:46:30 +0100 In-Reply-To: <20180302140211.GA3213@macbook41> (Efraim Flashner's message of "Fri, 2 Mar 2018 16:02:11 +0200") Message-ID: <871sh2e87t.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Efraim Flashner Cc: 29483@debbugs.gnu.org Hello, Efraim Flashner skribis: > On Mon, Feb 05, 2018 at 04:26:52PM +0100, Ludovic Court=C3=A8s wrote: >> Heya Efraim, >>=20 >> > +(define openntpd-shepherd-service >> > + (match-lambda >> > + (($ openntpd openntpd-listen-on >> > + openntpd-query-from openntpd-sensor openntpd-server >> > + openntpd-servers openntpd-constraint-from >> > + openntpd-constraints-from allow-large-adjustment?) >>=20 >> This is error prone (you could be matching the wrong fields), could you >> change that to =E2=80=98match-record=E2=80=99? >>=20 > > I think this is the only thing left over. To be clear, the switch from =E2=80=98match-lambda=E2=80=99 to =E2=80=98mat= ch-record=E2=80=99 should be entirely mechanical. The above snippet would become: (define (openntpd-shepherd-service config) (match-record config (openntpd openntpd-listen-on openntpd-query-from openntpd-sensor openntpd-server openntpd-servers openntpd-constraint-from openntpd-constraints-from allow-large-adjustment?) =E2=80=A6)) That=E2=80=99s all I was suggesting. The body of that procedure can remain unchanged. Does that make sense? Thanks, Ludo=E2=80=99.