Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Alex D
GHC
Commits
06f2a007
Commit
06f2a007
authored
Jul 20, 2008
by
Ian Lynagh
Browse files
Add a test for the WARNING pragma
parent
9b09753c
Changes
4
Hide whitespace changes
Inline
Side-by-side
testsuite/tests/ghc-regress/rename/should_compile/Rn066_A.hs
0 → 100644
View file @
06f2a007
module
Rn066_A
where
{-# WARNING C "Are you sure you want to do that?" #-}
{-# WARNING op "Is that really a good idea?" #-}
data
T
=
C
|
D
class
Foo
a
where
op
::
a
->
a
bop
::
a
->
a
testsuite/tests/ghc-regress/rename/should_compile/all.T
View file @
06f2a007
...
...
@@ -104,6 +104,10 @@ test('rn065',
multimod_compile
,
['
rn065
',
'
-v0
'])
test
('
rn066
',
extra_clean
(['
Rn066_A.hi
',
'
Rn066_A.o
']),
multimod_compile
,
['
rn066
',
'
-v0
'])
test
('
T1972
',
if_compiler_lt
('
ghc
',
'
6.9
',
expect_fail
),
compile
,
[''])
test
('
T2205
',
normal
,
compile
,
[''])
...
...
testsuite/tests/ghc-regress/rename/should_compile/rn066.hs
0 → 100644
View file @
06f2a007
{-# OPTIONS_GHC -fwarn-warnings-deprecations #-}
-- Test warnings on constructors and class ops
module
ShouldCompile
where
import
Rn066_A
instance
Foo
T
where
op
x
=
x
bop
y
=
y
foo
=
op
C
testsuite/tests/ghc-regress/rename/should_compile/rn066.stderr
0 → 100644
View file @
06f2a007
rn066.hs:7:0:
Warning: In the use of data constructor `C'
(imported from Rn066_A):
"Are you sure you want to do that?"
rn066.hs:7:0:
Warning: In the use of `op'
(imported from Rn066_A):
"Is that really a good idea?"
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