diff options
author | Thomas Miedema <thomasmiedema@gmail.com> | 2016-06-18 22:44:19 +0200 |
---|---|---|
committer | Thomas Miedema <thomasmiedema@gmail.com> | 2016-06-20 16:22:07 +0200 |
commit | a7160faafd44d64c2b20a4cc65e80136a93e1aaa (patch) | |
tree | c0fa999a4696a5a05e861b0eacfcd92358d77a48 /testsuite/tests/deSugar/should_run | |
parent | 5b03dc69389dc387b922c589ab9a8b92079e6a96 (diff) | |
download | haskell-a7160faafd44d64c2b20a4cc65e80136a93e1aaa.tar.gz |
Testsuite: tabs -> spaces [skip ci]
Diffstat (limited to 'testsuite/tests/deSugar/should_run')
-rw-r--r-- | testsuite/tests/deSugar/should_run/T246.hs | 12 | ||||
-rw-r--r-- | testsuite/tests/deSugar/should_run/dsrun001.hs | 6 | ||||
-rw-r--r-- | testsuite/tests/deSugar/should_run/dsrun002.hs | 12 | ||||
-rw-r--r-- | testsuite/tests/deSugar/should_run/dsrun003.hs | 8 | ||||
-rw-r--r-- | testsuite/tests/deSugar/should_run/dsrun004.hs | 2 | ||||
-rw-r--r-- | testsuite/tests/deSugar/should_run/dsrun005.hs | 14 | ||||
-rw-r--r-- | testsuite/tests/deSugar/should_run/dsrun006.hs | 16 | ||||
-rw-r--r-- | testsuite/tests/deSugar/should_run/dsrun010.hs | 4 | ||||
-rw-r--r-- | testsuite/tests/deSugar/should_run/dsrun014.hs | 2 |
9 files changed, 38 insertions, 38 deletions
diff --git a/testsuite/tests/deSugar/should_run/T246.hs b/testsuite/tests/deSugar/should_run/T246.hs index 835e618b79..448141cd65 100644 --- a/testsuite/tests/deSugar/should_run/T246.hs +++ b/testsuite/tests/deSugar/should_run/T246.hs @@ -16,10 +16,10 @@ g _ = "Odd3" funny = T { x = undefined, y = False } main = do { print (f funny) -- Should work, because we test - -- y first, which fails, and falls - -- through to "OK" + -- y first, which fails, and falls + -- through to "OK" - ; Control.Exception.catch - (print (g funny)) -- Should fail, because we test - (\(_::SomeException) -> print "caught") -- x first, and hit "undefined" - } + ; Control.Exception.catch + (print (g funny)) -- Should fail, because we test + (\(_::SomeException) -> print "caught") -- x first, and hit "undefined" + } diff --git a/testsuite/tests/deSugar/should_run/dsrun001.hs b/testsuite/tests/deSugar/should_run/dsrun001.hs index e40ea2a11d..904926ca3e 100644 --- a/testsuite/tests/deSugar/should_run/dsrun001.hs +++ b/testsuite/tests/deSugar/should_run/dsrun001.hs @@ -1,6 +1,6 @@ -{- Check that list comprehensions can be written - in do-notation. This actually broke 2.02, with - a pattern match failure in dsListComp! +{- Check that list comprehensions can be written + in do-notation. This actually broke 2.02, with + a pattern match failure in dsListComp! -} module Main where diff --git a/testsuite/tests/deSugar/should_run/dsrun002.hs b/testsuite/tests/deSugar/should_run/dsrun002.hs index acad275f74..09dc52d9de 100644 --- a/testsuite/tests/deSugar/should_run/dsrun002.hs +++ b/testsuite/tests/deSugar/should_run/dsrun002.hs @@ -3,12 +3,12 @@ module Main( main ) where foo = do - putStr "a" - let x = "b" in putStr x - putStr "c" + putStr "a" + let x = "b" in putStr x + putStr "c" main = do - putStr "a" - foo - let x = "b" in putStrLn x + putStr "a" + foo + let x = "b" in putStrLn x diff --git a/testsuite/tests/deSugar/should_run/dsrun003.hs b/testsuite/tests/deSugar/should_run/dsrun003.hs index d100bff718..94ca28ccf9 100644 --- a/testsuite/tests/deSugar/should_run/dsrun003.hs +++ b/testsuite/tests/deSugar/should_run/dsrun003.hs @@ -1,10 +1,10 @@ --- Tests match on empty field lists +-- Tests match on empty field lists module Main where -data Person = Female {firstName, lastName :: String} - | Male {firstName, lastName :: String} - deriving (Show) +data Person = Female {firstName, lastName :: String} + | Male {firstName, lastName :: String} + deriving (Show) isFemale (Female{}) = True isFemale (Male{}) = False diff --git a/testsuite/tests/deSugar/should_run/dsrun004.hs b/testsuite/tests/deSugar/should_run/dsrun004.hs index 8f54e330e1..555e11bb63 100644 --- a/testsuite/tests/deSugar/should_run/dsrun004.hs +++ b/testsuite/tests/deSugar/should_run/dsrun004.hs @@ -9,5 +9,5 @@ f (n+1) = n g :: Int -> Int g (n+4) = n -main = print (f 3) >> +main = print (f 3) >> print (g 9) diff --git a/testsuite/tests/deSugar/should_run/dsrun005.hs b/testsuite/tests/deSugar/should_run/dsrun005.hs index 238a2c3410..5ec70a377d 100644 --- a/testsuite/tests/deSugar/should_run/dsrun005.hs +++ b/testsuite/tests/deSugar/should_run/dsrun005.hs @@ -1,13 +1,13 @@ -{- +{- From: Olaf Chitil <chitil@Informatik.RWTH-Aachen.DE> It is a problem with 0.29 (which we use for compiling 2.01), it is gone in 2.01. - f :: Eq a => a -> [b] -> [b] -> Bool - f a [] [] = (a==a) - main = print (f True "" "Hallo") + f :: Eq a => a -> [b] -> [b] -> Bool + f a [] [] = (a==a) + main = print (f True "" "Hallo") when run after compilation with 0.29 you get: @@ -18,9 +18,9 @@ Fail: In pattern-matching: function f{-aYw-}; at test.hs, line 6 The problem is the dictionary, because for the program - f :: a -> [b] -> [b] -> Bool - f a [] [] = True - main = print (f True "" "Hallo") + f :: a -> [b] -> [b] -> Bool + f a [] [] = True + main = print (f True "" "Hallo") 0.29 gives the function name "f" as well. diff --git a/testsuite/tests/deSugar/should_run/dsrun006.hs b/testsuite/tests/deSugar/should_run/dsrun006.hs index 759c9c542d..dc31dac6b8 100644 --- a/testsuite/tests/deSugar/should_run/dsrun006.hs +++ b/testsuite/tests/deSugar/should_run/dsrun006.hs @@ -1,23 +1,23 @@ -{- +{- Date: Tue, 20 May 1997 05:10:04 GMT From: Tomasz Cholewo <tjchol01@mecca.spd.louisville.edu> ghc-2.03 cannot compile the following code, which I think is correct according to the Report - data X = A {a :: Int} | B {a :: Int} + data X = A {a :: Int} | B {a :: Int} -The error message is: +The error message is: Conflicting definitions for: a - Defined at bug4.lhs:2 - Defined at bug4.lhs:2 + Defined at bug4.lhs:2 + Defined at bug4.lhs:2 In addition the following snippet - data X = A {a :: Int} - y = let A {a} = x - in a + data X = A {a :: Int} + y = let A {a} = x + in a fails with: diff --git a/testsuite/tests/deSugar/should_run/dsrun010.hs b/testsuite/tests/deSugar/should_run/dsrun010.hs index 99a9297f8b..4b8bf4e1bc 100644 --- a/testsuite/tests/deSugar/should_run/dsrun010.hs +++ b/testsuite/tests/deSugar/should_run/dsrun010.hs @@ -9,10 +9,10 @@ test :: (MonadPlus m) => [a] -> m Bool test xs = do (_:_) <- return xs - -- Should fail here + -- Should fail here return True `mplus` - -- Failure in LH arg should trigger RH arg + -- Failure in LH arg should trigger RH arg do return False diff --git a/testsuite/tests/deSugar/should_run/dsrun014.hs b/testsuite/tests/deSugar/should_run/dsrun014.hs index 3b08a7ebf0..8e72aaad1f 100644 --- a/testsuite/tests/deSugar/should_run/dsrun014.hs +++ b/testsuite/tests/deSugar/should_run/dsrun014.hs @@ -10,7 +10,7 @@ f x y = x `seq` y `seq` (# x,y #) g :: Int -> Int -> Int g v w = case f v w of - (# a,b #) -> a+b + (# a,b #) -> a+b main = print (g (trace "one" 1) (trace "two" 2)) -- The args should be evaluated in the right order! |