[haskell][server]: Set "AnyType" to Aeson.Value (#9733)

* [haskell][server]: Set "AnyType" to `Aeson.Value`

`AnyType` would not be translated to the json value type.
This fixes that.

* [haskell][server] Fix haddock error in `API.hs`

Haddock (the Haskell documentation generator) would choke on the
misplaced docstring. The heading has to appear inside the list.
This commit is contained in:
Profpatsch 2021-06-14 11:00:11 +02:00 committed by GitHub
parent 856eca4ee6
commit cdb92086db
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions

View File

@ -201,6 +201,7 @@ public class HaskellServantCodegen extends DefaultCodegen implements CodegenConf
typeMapping.put("number", "Double");
typeMapping.put("BigDecimal", "Double");
typeMapping.put("any", "Value");
typeMapping.put("AnyType", "Value");
typeMapping.put("UUID", "UUID");
typeMapping.put("URI", "Text");
typeMapping.put("ByteArray", "Text");

View File

@ -14,8 +14,8 @@
-fno-warn-unused-binds -fno-warn-unused-imports -freduction-depth=328 #-}
module {{title}}.API
-- * Client and Server
( Config(..)
( -- * Client and Server
Config(..)
, {{title}}Backend(..)
, create{{title}}Client
, run{{title}}Server