unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: Alexandru-Sergiu Marton <brown121407@posteo.ro>
To: 42722@debbugs.gnu.org
Cc: Alexandru-Sergiu Marton <brown121407@posteo.ro>
Subject: [bug#42722] [PATCH 2/4] gnu: Add ghc-text-short.
Date: Wed,  5 Aug 2020 18:57:23 +0300	[thread overview]
Message-ID: <20200805155725.19931-2-brown121407@posteo.ro> (raw)
In-Reply-To: <20200805155725.19931-1-brown121407@posteo.ro>

* gnu/packages/haskell-xyz.scm (ghc-text-short): New variable.
---
 gnu/packages/haskell-xyz.scm | 41 ++++++++++++++++++++++++++++++++++++
 1 file changed, 41 insertions(+)

diff --git a/gnu/packages/haskell-xyz.scm b/gnu/packages/haskell-xyz.scm
index 54c77653cc..4d07eb7ea6 100644
--- a/gnu/packages/haskell-xyz.scm
+++ b/gnu/packages/haskell-xyz.scm
@@ -12579,6 +12579,47 @@ upgraded.  Consider yourself warned!")
 string metrics efficiently.")
     (license license:bsd-3)))
 
+(define-public ghc-text-short
+  (package
+    (name "ghc-text-short")
+    (version "0.1.3")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append
+             "https://hackage.haskell.org/package/text-short/text-short-"
+             version
+             ".tar.gz"))
+       (sha256
+        (base32
+         "0xyrxlb602z8bc9sr2y1fag0x56a20yj5qrkvy7iwc6hnznrynxz"))))
+    (build-system haskell-build-system)
+    (inputs `(("ghc-hashable" ,ghc-hashable)))
+    (native-inputs
+     `(("ghc-tasty" ,ghc-tasty)
+       ("ghc-tasty-quickcheck" ,ghc-tasty-quickcheck)
+       ("ghc-tasty-hunit" ,ghc-tasty-hunit)
+       ("ghc-quickcheck-instances"
+        ,ghc-quickcheck-instances)))
+    (arguments
+     `(#:cabal-revision
+       ("2"
+        "17cb7p0qywf2dsrq3g8qb3ssknd9wl5k0nc2pxz9gc3l8rxpkw51")))
+    (home-page
+     "http://hackage.haskell.org/package/text-short")
+    (synopsis
+     "Memory-efficient representation of Unicode text strings")
+    (description
+     "This package provides the @code{ShortText} type which is suitable for
+keeping many short strings in memory.  This is similiar to how
+@code{ShortByteString} relates to @code{ByteString}.  The main difference
+between @code{Text} and @code{ShortText} is that @code{ShortText} uses UTF-8
+instead of UTF-16 internally and also doesn't support zero-copy
+slicing (thereby saving 2 words).  Consequently, the memory footprint of
+a (boxed) @code{ShortText} value is 4 words (2 words when unboxed) plus the
+length of the UTF-8 encoded payload.")
+    (license license:bsd-3)))
+
 (define-public ghc-tf-random
   (package
     (name "ghc-tf-random")
-- 
2.28.0





  reply	other threads:[~2020-08-05 15:59 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-05 15:54 [bug#42722] [PATCH 0/4] Add some Haskell packages Alexandru-Sergiu Marton
2020-08-05 15:57 ` [bug#42722] [PATCH 1/4] gnu: Add ghc-quickcheck-text Alexandru-Sergiu Marton
2020-08-05 15:57   ` Alexandru-Sergiu Marton [this message]
2020-08-05 15:57   ` [bug#42722] [PATCH 3/4] gnu: Add ghc-deferred-folds Alexandru-Sergiu Marton
2020-08-05 15:57   ` [bug#42722] [PATCH 4/4] gnu: Add ghc-mtl-prelude Alexandru-Sergiu Marton
2020-08-07 18:12 ` [bug#42722] [PATCH 0/4] Add some Haskell packages Brett Gilio
2020-12-15 20:56   ` Leo Famulari

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200805155725.19931-2-brown121407@posteo.ro \
    --to=brown121407@posteo.ro \
    --cc=42722@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).