guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

07/125: gnu: Add r-curry.


From: guix-commits
Subject: 07/125: gnu: Add r-curry.
Date: Tue, 4 May 2021 01:33:05 -0400 (EDT)

rekado pushed a commit to branch master
in repository guix.

commit 6c07e74106fdf202422a6f1ea8802e680e4099c0
Author: Ricardo Wurmus <rekado@elephly.net>
AuthorDate: Tue May 4 07:11:02 2021 +0200

    gnu: Add r-curry.
    
    * gnu/packages/cran.scm (r-curry): New variable.
---
 gnu/packages/cran.scm | 29 +++++++++++++++++++++++++++++
 1 file changed, 29 insertions(+)

diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm
index 0269838..280c8ef 100644
--- a/gnu/packages/cran.scm
+++ b/gnu/packages/cran.scm
@@ -153,6 +153,35 @@ can limit either their total size or the age of the oldest 
object (or both),
 automatically pruning objects to maintain the constraints.")
     (license license:expat)))
 
+(define-public r-curry
+  (package
+    (name "r-curry")
+    (version "0.1.1")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (cran-uri "curry" version))
+       (sha256
+        (base32
+         "1ps9hvbnb02m0b8hlw4admwbziyjvswj08ldi2dk3ymnrpawcc29"))))
+    (properties `((upstream-name . "curry")))
+    (build-system r-build-system)
+    (home-page "https://github.com/thomasp85/curry";)
+    (synopsis "Partial function application")
+    (description
+     "Partial application is the process of reducing the arity of a function
+by fixing one or more arguments, thus creating a new function lacking the
+fixed arguments.  The @code{curry} package provides three different ways of
+performing partial function application by fixing arguments from either end of
+the argument list (currying and tail currying) or by fixing multiple named
+arguments (partial application).  This package provides this functionality
+through the @code{%<%}, @code{%-<%}, and @code{%><%} operators which allows
+for a programming style comparable to modern functional languages.  Compared
+to other implementations such a @code{purrr::partial()} the operators in
+@code{curry} composes functions with named arguments, aiding in autocomplete
+etc.")
+    (license license:gpl2+)))
+
 (define-public r-diffobj
   (package
     (name "r-diffobj")



reply via email to

[Prev in Thread] Current Thread [Next in Thread]