[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] gnu: sdl-union: Wrap into a procedure and export it.
From: |
Ludovic Courtès |
Subject: |
Re: [PATCH] gnu: sdl-union: Wrap into a procedure and export it. |
Date: |
Sun, 11 Oct 2015 18:50:39 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) |
Alex Kost <address@hidden> skribis:
> From f1bd9edbbae498fb3b4726428daf523e3fd83060 Mon Sep 17 00:00:00 2001
> From: Alex Kost <address@hidden>
> 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 <address@hidden>.
>
> * 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’.
Re: [PATCH 2/2] gnu: Add manaplus., Alex Kost, 2015/10/10
- Re: [PATCH 2/2] gnu: Add manaplus., Ludovic Courtès, 2015/10/11
- Re: [PATCH 2/2] gnu: Add manaplus., Alex Kost, 2015/10/12
- Re: [PATCH 2/2] gnu: Add manaplus., Ludovic Courtès, 2015/10/12
- [PATCH] gnu: abbaye: Use 'sdl-union'., Alex Kost, 2015/10/13
- Re: [PATCH] gnu: abbaye: Use 'sdl-union'., Thompson, David, 2015/10/13
- Re: [PATCH] gnu: abbaye: Use 'sdl-union'., Alex Kost, 2015/10/14