summaryrefslogtreecommitdiff
path: root/testsuite/tests/ghc-api/T9015.stdout
diff options
context:
space:
mode:
authorRoman Shatsov <roshats@gmail.com>2015-12-07 11:24:36 +0100
committerBen Gamari <ben@smart-cactus.org>2015-12-07 12:15:03 +0100
commit2110037e270c5ea36de63e4d95a3175751338571 (patch)
tree3079e261df8c29491fdb6a7049d5a3d1d4316642 /testsuite/tests/ghc-api/T9015.stdout
parent91e985cd99e9f628e7cd01fc5dd0e6f596337446 (diff)
downloadhaskell-2110037e270c5ea36de63e4d95a3175751338571.tar.gz
Add isImport, isDecl, and isStmt functions to GHC API
Reviewers: austin, thomie, bgamari Reviewed By: thomie, bgamari Subscribers: mpickering, thomie Differential Revision: https://phabricator.haskell.org/D1518 GHC Trac Issues: #9015
Diffstat (limited to 'testsuite/tests/ghc-api/T9015.stdout')
-rw-r--r--testsuite/tests/ghc-api/T9015.stdout86
1 files changed, 86 insertions, 0 deletions
diff --git a/testsuite/tests/ghc-api/T9015.stdout b/testsuite/tests/ghc-api/T9015.stdout
new file mode 100644
index 0000000000..7b9b6e92de
--- /dev/null
+++ b/testsuite/tests/ghc-api/T9015.stdout
@@ -0,0 +1,86 @@
+Is import:
+import Data.Maybe: True
+import qualified Data.Maybe: True
+import Data.Maybe (isJust): True
+add a b = a+b: False
+data Foo = Foo String: False
+deriving instance Show Foo: False
+{-# NOVECTORISE foo #-}: False
+{-# WARNING Foo "Just a warning" #-}: False
+{-# ANN foo (Just "Hello") #-}: False
+{-# RULES "map/map" forall f g xs. map f (map g xs) = map (f.g) xs #-}: False
+class HasString a where
+ update :: a -> (String -> String) -> a
+ upcase :: a -> a
+ upcase x = update x (fmap toUpper)
+ content :: a -> String
+ default content :: Show a => a -> String
+ content = show: False
+instance HasString Foo where
+ update (Foo s) f = Foo (f s)
+ content (Foo s) = s: False
+add a b: False
+let foo = add a b: False
+x <- foo y: False
+5 + 8: False
+a <-: False
+2 +: False
+@#: False
+
+Is declaration:
+import Data.Maybe: False
+import qualified Data.Maybe: False
+import Data.Maybe (isJust): False
+add a b = a+b: True
+data Foo = Foo String: True
+deriving instance Show Foo: True
+{-# NOVECTORISE foo #-}: True
+{-# WARNING Foo "Just a warning" #-}: True
+{-# ANN foo (Just "Hello") #-}: True
+{-# RULES "map/map" forall f g xs. map f (map g xs) = map (f.g) xs #-}: True
+class HasString a where
+ update :: a -> (String -> String) -> a
+ upcase :: a -> a
+ upcase x = update x (fmap toUpper)
+ content :: a -> String
+ default content :: Show a => a -> String
+ content = show: True
+instance HasString Foo where
+ update (Foo s) f = Foo (f s)
+ content (Foo s) = s: True
+add a b: False
+let foo = add a b: False
+x <- foo y: False
+5 + 8: False
+a <-: False
+2 +: False
+@#: False
+
+Is statement:
+import Data.Maybe: False
+import qualified Data.Maybe: False
+import Data.Maybe (isJust): False
+add a b = a+b: False
+data Foo = Foo String: False
+deriving instance Show Foo: False
+{-# NOVECTORISE foo #-}: False
+{-# WARNING Foo "Just a warning" #-}: False
+{-# ANN foo (Just "Hello") #-}: False
+{-# RULES "map/map" forall f g xs. map f (map g xs) = map (f.g) xs #-}: False
+class HasString a where
+ update :: a -> (String -> String) -> a
+ upcase :: a -> a
+ upcase x = update x (fmap toUpper)
+ content :: a -> String
+ default content :: Show a => a -> String
+ content = show: False
+instance HasString Foo where
+ update (Foo s) f = Foo (f s)
+ content (Foo s) = s: False
+add a b: True
+let foo = add a b: True
+x <- foo y: True
+5 + 8: True
+a <-: False
+2 +: False
+@#: False