File tree Expand file tree Collapse file tree 1 file changed +6
-9
lines changed
src/GraphQL/Internal/Value Expand file tree Collapse file tree 1 file changed +6
-9
lines changed Original file line number Diff line number Diff line change @@ -100,15 +100,12 @@ instance forall dataName consName records s l p.
100
100
)) where
101
101
genericFromValue o = M1 . M1 <$> genericFromValue @ records o
102
102
103
- instance forall wrappedType fieldName rest u s l .
104
- ( KnownSymbol fieldName
105
- , FromValue wrappedType
106
- , GenericFromValue rest
107
- ) => GenericFromValue (S1 ('MetaSel ('Just fieldName ) u s l ) (Rec0 wrappedType ) :*: rest ) where
108
- genericFromValue object = do
109
- l <- getValue @ wrappedType @ fieldName object
110
- r <- genericFromValue @ rest object
111
- pure (l :*: r)
103
+
104
+ instance forall l r .
105
+ ( GenericFromValue l
106
+ , GenericFromValue r
107
+ ) => GenericFromValue (l :*: r ) where
108
+ genericFromValue object = liftA2 (:*:) (genericFromValue @ l object) (genericFromValue @ r object)
112
109
113
110
-- | Look up a single record field element in the Object.
114
111
getValue :: forall wrappedType fieldName u s l p . (FromValue wrappedType , KnownSymbol fieldName )
You can’t perform that action at this time.
0 commit comments