Popularity
8.2
Stable
Activity
6.8
Stable
45
4
11
Monthly Downloads: 330
Programming language: Haskell
License: BSD 3-clause "New" or "Revised" License
Tags:
Unclassified
safe alternatives and similar packages
Based on the "Unclassified" category.
Alternatively, view safe alternatives based on common mentions on social networks and blogs.
-
bit-stream
Lazy infinite compact streams with cache-friendly O(1) indexing and applications for memoization -
dependent-sum-template
DISCONTINUED. Template Haskell code to generate instances of classes in dependent-sum package -
argon2
Haskell bindings to libargon2 - the reference implementation of the Argon2 password-hashing function -
network-carbon
A Haskell implementation of the Carbon protocol (part of the Graphite monitoring tools)
CodeRabbit: AI Code Reviews for Developers
Revolutionize your code reviews with AI. CodeRabbit offers PR summaries, code walkthroughs, 1-click suggestions, and AST-based analysis. Boost productivity and code quality across all major languages with each PR.
Promo
coderabbit.ai
* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of safe or a related project?
Popular Comparisons
README
Safe
A library wrapping Prelude
/Data.List
functions that can throw exceptions, such as head
and !!
. Each unsafe function has up to four variants, e.g. with tail
:
- tail :: [a] -> [a], raises an error on
tail []
. - tailMay :: [a] -> Maybe [a], turns errors into
Nothing
. - tailDef :: [a] -> [a] -> [a], takes a default to return on errors.
- tailNote :: String -> [a] -> [a], takes an extra argument which supplements the error message.
- tailSafe :: [a] -> [a], returns some sensible default if possible,
[]
in the case oftail
.
This package is divided into three modules:
Safe
contains safe variants ofPrelude
andData.List
functions.Safe.Foldable
contains safe variants ofFoldable
functions.Safe.Exact
creates crashing versions of functions likezip
(errors if the lists are not equal) andtake
(errors if there are not enough elements), then wraps them to provide safe variants.