Fix module list in ipkg

This commit is contained in:
Kiana Sheibani 2023-04-20 19:19:13 -04:00
parent f6508074a6
commit 27247861d6
Signed by: toki
GPG key ID: 6CB106C25E86A9F7
4 changed files with 19 additions and 5 deletions

View file

@ -13,10 +13,13 @@ langversion >= 0.6.0
depends = profunctors >= 1.1.2 depends = profunctors >= 1.1.2
modules = Control.Applicative.Backwards, modules = Control.Applicative.Backwards,
Control.Applicative.Indexing,
Control.Lens.At,
Control.Lens.Equality, Control.Lens.Equality,
Control.Lens.Fold, Control.Lens.Fold,
Control.Lens.Getter, Control.Lens.Getter,
Control.Lens.Iso, Control.Lens.Iso,
Control.Lens.Indexed,
Control.Lens.Lens, Control.Lens.Lens,
Control.Lens.Optic, Control.Lens.Optic,
Control.Lens.Optional, Control.Lens.Optional,
@ -26,4 +29,9 @@ modules = Control.Applicative.Backwards,
Control.Lens.Setter, Control.Lens.Setter,
Control.Lens.Traversal, Control.Lens.Traversal,
Control.Lens, Control.Lens,
Data.Bicontravariant Data.Bicontravariant,
Data.Either.Lens,
Data.List.Lens,
Data.Maybe.Lens,
Data.Tuple.Lens,
Data.Vect.Lens

View file

@ -73,10 +73,13 @@ public export
view : Getter s a -> s -> a view : Getter s a -> s -> a
view l = views l id view l = views l id
||| Access the value and index of an optic and apply a function to them,
||| returning the result.
public export public export
iviews : IndexedGetter i s a -> (i -> a -> r) -> s -> r iviews : IndexedGetter i s a -> (i -> a -> r) -> s -> r
iviews l = runForget . l @{%search} @{Idxed} . MkForget . uncurry iviews l = runForget . l @{%search} @{Idxed} . MkForget . uncurry
||| Access the focus value and index of an optic, particularly a `Getter`.
public export public export
iview : IndexedGetter i s a -> s -> (i, a) iview : IndexedGetter i s a -> s -> (i, a)
iview l = runForget $ l @{%search} @{Idxed} $ MkForget id iview l = runForget $ l @{%search} @{Idxed} $ MkForget id
@ -92,6 +95,9 @@ public export
(^.) : s -> Getter s a -> a (^.) : s -> Getter s a -> a
(^.) x l = view l x (^.) x l = view l x
||| Access the focus value and index of an optic, particularly a `Getter`.
|||
||| This is the operator form of `iview`.
public export public export
(^@.) : s -> IndexedGetter i s a -> (i, a) (^@.) : s -> IndexedGetter i s a -> (i, a)
(^@.) x l = iview l x (^@.) x l = iview l x

View file

@ -108,8 +108,8 @@ withLens l f = uncurry f (getLens l)
||| `Void` vacuously "contains" a value of any other type. ||| `Void` vacuously "contains" a value of any other type.
public export public export
devoid : IndexedLens i Void Void a b devoid : IndexedLens i Void t a b
devoid @{MkIsLens _} = ilens absurd const devoid = ilens absurd absurd
||| All values contain a unit. ||| All values contain a unit.
public export public export

View file

@ -9,8 +9,8 @@ import public Control.Lens
||| A prism of the `Nothing` case of a `Maybe`. ||| A prism of the `Nothing` case of a `Maybe`.
public export public export
Nothing_ : Prism' (Maybe a) () Nothing_ : Prism (Maybe a) (Maybe b) () ()
Nothing_ = prism' (const Nothing) (guard . isNothing) Nothing_ = prism (const Nothing) (maybe (Right ()) (const $ Left Nothing))
||| A prism of the `Just` case of a `Maybe`. ||| A prism of the `Just` case of a `Maybe`.
public export public export