on master help sign in
Implement _Type directly
d1cda62Matthew Pickering
src/Data/Generics/Sum/Typed.hs+1−1
@@ -98,7 +98,7 @@ instance
98 ) => AsType a s where
98 ) => AsType a s where
99
99
100 _Typed
100 _Typed
101− = repIso . _GTyped
101+ = prism injectTyped (either (Left . to) Right . gprojectTyped . from)
102 injectTyped
102 injectTyped
103 = to . ginjectTyped
103 = to . ginjectTyped
104 projectTyped
104 projectTyped