Alex Kost <alez...@gmail.com> skribis: > From f1bd9edbbae498fb3b4726428daf523e3fd83060 Mon Sep 17 00:00:00 2001 > From: Alex Kost <alez...@gmail.com> > Date: Sat, 10 Oct 2015 11:27:27 +0300 > Subject: [PATCH] gnu: sdl-union: Wrap into a procedure and export it. > MIME-Version: 1.0 > Content-Type: text/plain; charset=UTF-8 > Content-Transfer-Encoding: 8bit > > Suggested by Ludovic Courtès <l...@gnu.org>. > > * gnu/packages/sdl.scm (sdl-union): Make it a procedure returning > 'sdl-union' package. > (guile-sdl): Use it.
I like this idea. > +(define (sdl-union . sdl-packages) > + "Return 'sdl-union' package that is the union of SDL-PACKAGES. > +If SDL-PACKAGES are not specified, all SDL libraries are used." > + (let* ((sdl-packages (if (null? sdl-packages) > + (list sdl > + sdl-gfx > + sdl-image > + sdl-mixer > + sdl-net > + sdl-ttf) > + sdl-packages)) What about writing it like this: (define* (sdl-union #:optional (packages (list sdl sdl-gfx …))) …) That would be more concise and more idiomatic. If that’s fine with you, OK to push with this change. Thanks! Ludo’.