@@ -1,3 +1,4 @@
1+{-# LANGUAGE CPP #-}
12{-# LANGUAGE DataKinds #-}
23{-# LANGUAGE FlexibleContexts #-}
34{-# LANGUAGE GADTs #-}
@@ -138,7 +139,15 @@ sopSwaggerGenericToJSON'
138139 -> DatatypeInfo '[xs]
139140 -> POP Maybe '[xs]
140141 -> [Pair]
141−sopSwaggerGenericToJSON' opts (SOP (Z fields)) (ADT _ _ (Record _ fieldsInfo :* Nil) _) (POP (defs :* Nil)) =
142+sopSwaggerGenericToJSON'
143+ opts
144+ (SOP (Z fields))
145+#if MIN_VERSION_generics_sop(0,5,0)
146+ (ADT _ _ (Record _ fieldsInfo :* Nil) _)
147+#else
148+ (ADT _ _ (Record _ fieldsInfo :* Nil))
149+#endif
150+ (POP (defs :* Nil)) =
142151 sopSwaggerGenericToJSON'' opts fields fieldsInfo defs
143152sopSwaggerGenericToJSON' _ _ _ _ = error "sopSwaggerGenericToJSON: unsupported type"
144153
@@ -211,7 +220,15 @@ sopSwaggerGenericParseJSON'
211220 -> DatatypeInfo '[xs]
212221 -> POP Maybe '[xs]
213222 -> Parser (SOP I '[xs])
214−sopSwaggerGenericParseJSON' opts obj (ADT _ _ (Record _ fieldsInfo :* Nil) _) (POP (defs :* Nil)) =
223+sopSwaggerGenericParseJSON'
224+ opts
225+ obj
226+#if MIN_VERSION_generics_sop(0,5,0)
227+ (ADT _ _ (Record _ fieldsInfo :* Nil) _)
228+#else
229+ (ADT _ _ (Record _ fieldsInfo :* Nil))
230+#endif
231+ (POP (defs :* Nil)) =
215232 SOP . Z <$> sopSwaggerGenericParseJSON'' opts obj fieldsInfo defs
216233sopSwaggerGenericParseJSON' _ _ _ _ = error "sopSwaggerGenericParseJSON: unsupported type"
217234
@@ -278,7 +295,15 @@ sopSwaggerGenericToEncoding'
278295 -> DatatypeInfo '[xs]
279296 -> POP Maybe '[xs]
280297 -> Series
281−sopSwaggerGenericToEncoding' opts (SOP (Z fields)) (ADT _ _ (Record _ fieldsInfo :* Nil) _) (POP (defs :* Nil)) =
298+sopSwaggerGenericToEncoding'
299+ opts
300+ (SOP (Z fields))
301+#if MIN_VERSION_generics_sop(0,5,0)
302+ (ADT _ _ (Record _ fieldsInfo :* Nil) _)
303+#else
304+ (ADT _ _ (Record _ fieldsInfo :* Nil))
305+#endif
306+ (POP (defs :* Nil)) =
282307 sopSwaggerGenericToEncoding'' opts fields fieldsInfo defs
283308sopSwaggerGenericToEncoding' _ _ _ _ = error "sopSwaggerGenericToEncoding: unsupported type"
284309