@@ -32,6 +32,8 @@
33-- deriving (Show, Generic)
33-- deriving (Show, Generic)
35-- >>> Bar 5 "coconut" ^? as @"Bar"
37-- >>> Bar 5 "coconut" ^? as @"Bar"
36-- Just (5, "coconut")
38-- Just (5, "coconut")
@@ -41,16 +43,12 @@
41-- >>> as @"Bar" # (5, "asd") :: FooBar
43-- >>> as @"Bar" # (5, "asd") :: FooBar
42-- Bar 5 "asd"
44-- Bar 5 "asd"
44−-- >>> as @"Barz" # (5, "asd") :: FooBar
46−-- <interactive>:264:1: error:
47−-- • FooBar has no constructor with name "Barz"
51-----------------------------------------------------------------------------
47-----------------------------------------------------------------------------
53−module Data.Generics.Sum.HasConstructor where
49+module Data.Generics.Sum.HasConstructor
50+ ( HasConstructor (..)
55import Data.Generics.Internal.Lens
53import Data.Generics.Internal.Lens