data-default-instances-new-base: Default instances for types in newer versions of base package.
Orphan instances for Default type class, which is defined in package
data-default-class.
In addition to instances reexported from
data-default-instances-base
package, following Default instances are provided:
instance Default a => Default (Const a b) where
def = Const def
instance Monad m => Default (Kleisli m a b) where
def = Kleisli return
instance Default Version where
def = Version [] []Following instances are available only for base >= 4.7.0.0:
instance Default (Proxy a) where
def = Proxy
instance Default SomeNat where
def = SomeNat (Proxy :: Proxy 0)
instance Default SomeNat where
def = SomeSymbol (Proxy :: Proxy "")Following instances are available only for base >= 4.8.0.0:
instance Alternative f => Default (Alt f a) where
def = Alt empty
instance Default a => Default (Identity a) where
def = Identity def
instance Default Natural where
def = 0Following instances are available only for base >= 4.9.0.0:
instance Default a => Default (NonEmpty a) where
def = def :| []
instance Bounded a => Default (Min a) where
def = minBound
instance Bounded a => Default (Max a) where
def = maxBound
instance Default (Option a) where
def = Option Nothing
[Skip to Readme]
Downloads
- data-default-instances-new-base-0.0.1.tar.gz [browse] (Cabal source package)
- Package description (revised from the package)
Note: This package has metadata revisions in the cabal description newer than included in the tarball. To unpack the package including the revisions, use 'cabal get'.
Maintainer's Corner
For package maintainers and hackage trustees
Candidates
| Versions [RSS] | 0.0.1, 0.0.2 |
|---|---|
| Change log | ChangeLog.md |
| Dependencies | base (>=4 && <5), data-default-class (>=0.0 && <0.2), data-default-instances-base (>=0.0 && <0.2) [details] |
| License | BSD-3-Clause |
| Copyright | (c) 2015-2016, Peter Trško |
| Author | Peter Trško |
| Maintainer | peter.trsko@gmail.com |
| Uploaded | by PeterTrsko at 2016-02-07T13:02:40Z |
| Revised | Revision 1 made by PeterTrsko at 2017-01-05T20:48:53Z |
| Category | Data |
| Home page | https://github.com/trskop/data-default-extra |
| Bug tracker | https://github.com/trskop/data-default-extra/issues |
| Source repo | head: git clone git://github.com/trskop/data-default-extra.git this: git clone git://github.com/trskop/data-default-extra.git(tag new-base-v0.0.1) |
| Distributions | |
| Reverse Dependencies | 1 direct, 4 indirect [details] |
| Downloads | 2829 total (3 in the last 30 days) |
| Rating | (no votes yet) [estimated by Bayesian average] |
| Your Rating | |
| Status | Docs available [build log] Last success reported on 2016-02-12 [all 1 reports] |