Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
curry
curry-frontend
Commits
51b64571
Commit
51b64571
authored
Jan 05, 2018
by
Finn Teegen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix prelude of testsuite
parent
43e7ee38
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
18 deletions
+18
-18
test/fail/Prelude.curry
test/fail/Prelude.curry
+6
-6
test/pass/Prelude.curry
test/pass/Prelude.curry
+6
-6
test/warning/Prelude.curry
test/warning/Prelude.curry
+6
-6
No files found.
test/fail/Prelude.curry
View file @
51b64571
...
...
@@ -1645,7 +1645,7 @@ class Num a where
abs :: a -> a
signum :: a -> a
fromInt
eger
:: Int -> a
fromInt :: Int -> a
x - y = x + negate y
negate x = 0 - x
...
...
@@ -1664,7 +1664,7 @@ instance Num Int where
| x == 0 = 0
| otherwise = -1
fromInt
eger
x = x
fromInt x = x
instance Num Float where
x + y = x +. y
...
...
@@ -1681,9 +1681,9 @@ instance Num Float where
| x == 0 = 0
| otherwise = -1
fromInt
eger
x = i2f x
fromInt x = i2f x
-- minimal definition: from
Rational
and (recip or (/))
-- minimal definition: from
Float
and (recip or (/))
class Num a => Fractional a where
(/) :: a -> a -> a
...
...
@@ -1692,13 +1692,13 @@ class Num a => Fractional a where
recip x = 1/x
x / y = x * recip y
from
Rational
:: Float -> a -- since we have no type Rational
from
Float
:: Float -> a -- since we have no type Rational
instance Fractional Float where
x / y = x /. y
recip x = 1.0/x
from
Rational
x = x
from
Float
x = x
class (Num a, Ord a) => Real a where
-- toRational :: a -> Rational
...
...
test/pass/Prelude.curry
View file @
51b64571
...
...
@@ -1645,7 +1645,7 @@ class Num a where
abs :: a -> a
signum :: a -> a
fromInt
eger
:: Int -> a
fromInt :: Int -> a
x - y = x + negate y
negate x = 0 - x
...
...
@@ -1664,7 +1664,7 @@ instance Num Int where
| x == 0 = 0
| otherwise = -1
fromInt
eger
x = x
fromInt x = x
instance Num Float where
x + y = x +. y
...
...
@@ -1681,9 +1681,9 @@ instance Num Float where
| x == 0 = 0
| otherwise = -1
fromInt
eger
x = i2f x
fromInt x = i2f x
-- minimal definition: from
Rational
and (recip or (/))
-- minimal definition: from
Float
and (recip or (/))
class Num a => Fractional a where
(/) :: a -> a -> a
...
...
@@ -1692,13 +1692,13 @@ class Num a => Fractional a where
recip x = 1/x
x / y = x * recip y
from
Rational
:: Float -> a -- since we have no type Rational
from
Float
:: Float -> a -- since we have no type Rational
instance Fractional Float where
x / y = x /. y
recip x = 1.0/x
from
Rational
x = x
from
Float
x = x
class (Num a, Ord a) => Real a where
-- toRational :: a -> Rational
...
...
test/warning/Prelude.curry
View file @
51b64571
...
...
@@ -1645,7 +1645,7 @@ class Num a where
abs :: a -> a
signum :: a -> a
fromInt
eger
:: Int -> a
fromInt :: Int -> a
x - y = x + negate y
negate x = 0 - x
...
...
@@ -1664,7 +1664,7 @@ instance Num Int where
| x == 0 = 0
| otherwise = -1
fromInt
eger
x = x
fromInt x = x
instance Num Float where
x + y = x +. y
...
...
@@ -1681,9 +1681,9 @@ instance Num Float where
| x == 0 = 0
| otherwise = -1
fromInt
eger
x = i2f x
fromInt x = i2f x
-- minimal definition: from
Rational
and (recip or (/))
-- minimal definition: from
Float
and (recip or (/))
class Num a => Fractional a where
(/) :: a -> a -> a
...
...
@@ -1692,13 +1692,13 @@ class Num a => Fractional a where
recip x = 1/x
x / y = x * recip y
from
Rational
:: Float -> a -- since we have no type Rational
from
Float
:: Float -> a -- since we have no type Rational
instance Fractional Float where
x / y = x /. y
recip x = 1.0/x
from
Rational
x = x
from
Float
x = x
class (Num a, Ord a) => Real a where
-- toRational :: a -> Rational
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment