diff mbox series

[bug#67184,v2] gnu: Add python-multimethod.

Message ID 87sf393p44.fsf@troyfigiel.com
State New
Headers show
Series [bug#67184,v2] gnu: Add python-multimethod. | expand

Commit Message

Troy Figiel Jan. 7, 2024, 5:06 p.m. UTC
* gnu/packages/python-xyz.scm (python-multimethod): New variable.
---
 gnu/packages/python-xyz.scm | 24 ++++++++++++++++++++++++
 1 file changed, 24 insertions(+)


base-commit: 5f8a993aa85554ca09bd27139230d7664107e1b6

Comments

Mathieu Othacehe Jan. 9, 2024, 9:16 a.m. UTC | #1
> * gnu/packages/python-xyz.scm (python-multimethod): New variable.

Applied, thanks,

Mathieu
diff mbox series

Patch

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index f8bb943122..b378faf536 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -31628,6 +31628,30 @@  (define-public python-multipledispatch
 function implementations based on the types of the arguments.")
     (license license:bsd-3)))
 
+(define-public python-multimethod
+  (package
+    (name "python-multimethod")
+    (version "1.10")
+    (source
+     (origin
+       ;; No tests in the PyPI tarball.
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/coady/multimethod")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "07xv92q7f4bkp6dzkqvcv0zxr11729qdak4s3ldmbhdwgsf44g5h"))))
+    (build-system pyproject-build-system)
+    (native-inputs (list python-pytest))
+    (home-page "https://github.com/coady/multimethod")
+    (synopsis "Python support for multiple argument dispatching")
+    (description
+     "This package provides a decorator for adding multiple argument
+dispatching to functions.  The decorator creates a multimethod object as
+needed and registers the function with its annotations.")
+    (license license:asl2.0)))
+
 (define-public python-logical-unification
   (package
     (name "python-logical-unification")