mirror of
https://github.com/github/semantic.git
synced 2024-12-26 00:12:29 +03:00
remove Generic constraints
This commit is contained in:
parent
3304186ed5
commit
0d269d88ac
@ -23,9 +23,9 @@ import qualified Data.Text as Text
|
||||
|
||||
-- Serialize unmarshaled ASTs into JSON representation by auto-deriving Aeson instances generically
|
||||
class MarshalJSON t where
|
||||
marshal :: (ToJSON a) => t a -> Value
|
||||
default marshal :: ( Generic1 t, GMarshalJSON (Rep1 t), ToJSON a) => t a -> Value
|
||||
marshal = gmarshal . from1
|
||||
marshal :: (ToJSON a) => t a -> Value -- don't need default signature because they're the same now
|
||||
|
||||
-- Create MarshalJSON instances for each type constructor
|
||||
instance (GMarshalJSON (Rep1 t), Generic1 t) => MarshalJSON t
|
||||
|
Loading…
Reference in New Issue
Block a user