Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Glasgow Haskell Compiler
GHC
Commits
f9471769
Commit
f9471769
authored
Aug 22, 2005
by
simonpj
Browse files
[project @ 2005-08-22 08:59:15 by simonpj]
Slightly better overlap checking
parent
692af8d4
Changes
4
Hide whitespace changes
Inline
Side-by-side
testsuite/tests/ghc-regress/deSugar/should_compile/all.T
View file @
f9471769
...
...
@@ -59,3 +59,4 @@ test('ds052', expect_fail_if_compiler_type('ghc'), compile, [''])
test
('
ds053
',
normal
,
compile
,
[''])
test
('
ds054
',
normal
,
compile
,
[''])
test
('
ds055
',
only_compiler_types
(['
ghc
']),
compile
,
[''])
test
('
ds056
',
normal
,
compile
,
['
-Wall
'])
testsuite/tests/ghc-regress/deSugar/should_compile/ds040.stderr-ghc
View file @
f9471769
ds040.hs:9:0:
Warning: Pattern match(es) are overlapped
In the definition of `^^^^': ^^^^ _ _ = ...
testsuite/tests/ghc-regress/deSugar/should_compile/ds052.stderr
View file @
f9471769
ds052.hs:6:0:
Warning: Pattern match(es) are non-exhaustive
In the definition of `lazyZip': Patterns not matched: (_ : _) []
testsuite/tests/ghc-regress/deSugar/should_compile/ds056.hs
0 → 100644
View file @
f9471769
-- Check overlap in n+k patterns
module
Foo
where
g
::
Int
->
Int
g
(
x
+
1
)
=
x
g
y
=
y
g
_
=
0
-- Overlapped
h
::
Int
->
Int
h
(
x
+
1
)
=
x
h
_
=
0
-- Not overlapped
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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