From b7a72591fd08df9df678e5e7db3304b5a2e75ae9 Mon Sep 17 00:00:00 2001 From: Danny Navarro Date: Sun, 12 Feb 2017 15:19:13 -0300 Subject: Support variables in AST transformation --- Data/GraphQL/AST/Core.hs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Data/GraphQL/AST/Core.hs') diff --git a/Data/GraphQL/AST/Core.hs b/Data/GraphQL/AST/Core.hs index 3424d20..f0c617c 100644 --- a/Data/GraphQL/AST/Core.hs +++ b/Data/GraphQL/AST/Core.hs @@ -3,6 +3,7 @@ module Data.GraphQL.AST.Core where import Data.Int (Int32) import Data.List.NonEmpty (NonEmpty) +import Data.String import Data.Text (Text) @@ -31,4 +32,7 @@ data Value = ValueInt Int32 | ValueObject [ObjectField] deriving (Eq,Show) +instance IsString Value where + fromString = ValueString . fromString + data ObjectField = ObjectField Name Value deriving (Eq,Show) -- cgit v1.2.3