aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/golang-build.scm
diff options
context:
space:
mode:
authorSharlatan Hellseher <sharlatanus@gmail.com>2024-07-13 14:43:53 +0100
committerSharlatan Hellseher <sharlatanus@gmail.com>2024-07-15 12:17:48 +0100
commit2156dc644b3a1c3ed4df1785d52e325306ef2c9e (patch)
tree7899cedbbbf63fa55c1c9126d34af1c6b15b3d37 /gnu/packages/golang-build.scm
parenteefd68e0ee3f26f305b1a77c6f9871fff7b85654 (diff)
downloadguix-2156dc644b3a1c3ed4df1785d52e325306ef2c9e.tar
guix-2156dc644b3a1c3ed4df1785d52e325306ef2c9e.tar.gz
gnu: Add go-golang-org-x-exp-typeparams.
* gnu/packages/golang-build.scm (go-golang-org-x-exp-typeparams): New variable. Change-Id: I59e68dbf6492b35916dca6da84bc4216454b3f79
Diffstat (limited to 'gnu/packages/golang-build.scm')
-rw-r--r--gnu/packages/golang-build.scm34
1 files changed, 34 insertions, 0 deletions
diff --git a/gnu/packages/golang-build.scm b/gnu/packages/golang-build.scm
index 45bad64c4b..ea7d73dafa 100644
--- a/gnu/packages/golang-build.scm
+++ b/gnu/packages/golang-build.scm
@@ -160,6 +160,40 @@ for the Go language.")
@code{old} directory) packages.")
(license license:bsd-3)))
+(define-public go-golang-org-x-exp-typeparams
+ (package
+ (name "go-golang-org-x-exp-typeparams")
+ (version "0.0.0-20240707233637-46b078467d37")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://go.googlesource.com/exp")
+ (commit (go-version->git-ref version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "17pwikql9x1bm5ci0kk4mlad7smkph0cgq1pi2b43gnhjz8m96l0"))))
+ (build-system go-build-system)
+ (arguments
+ (list
+ #:import-path "golang.org/x/exp/typeparams"
+ #:unpack-path "golang.org/x/exp"))
+ (home-page "https://pkg.go.dev/golang.org/x/exp/typeparams")
+ (synopsis "Golang common utilities for writing tools")
+ (description
+ "Package typeparams contains common utilities for writing tools that
+interact with generic Go code, as introduced with Go 1.18.
+
+Many of the types and functions in this package are proxies for the new APIs
+introduced in the standard library with Go 1.18. For example, the
+typeparams.Union type is an alias for @code{go/types.Union}, and the
+@code{ForTypeSpec} function returns the value of the
+@code{go/ast.TypeSpec.TypeParams} field. At Go versions older than 1.18 these
+helpers are implemented as stubs, allowing users of this package to write code
+that handles generic constructs inline,even if the Go version being used to
+compile does not support generics.")
+ (license license:bsd-3)))
+
(define-public go-golang-org-x-image
(let ((commit "58c23975cae11f062d4b3b0c143fe248faac195d")
(revision "1"))