Commit 9f932d8a authored by Krzysztof Gogolewski's avatar Krzysztof Gogolewski

Add a test for Trac #15523

Summary: Fortunately the bug is not present in master.

Test Plan: make test TEST=T15523

Reviewers: bgamari, RyanGlScott

Reviewed By: RyanGlScott

Subscribers: RyanGlScott, rwbarton, carter

GHC Trac Issues: #15523

Differential Revision: https://phabricator.haskell.org/D5070
parent 29088992
{-# LANGUAGE StrictData #-}
module T15523 where
newtype Duration = Foo
data Literal = LitDuration Duration
T15523.hs:5:20: error:
• The constructor of a newtype must have exactly one field
but ‘Foo’ has none
• In the definition of data constructor ‘Foo’
In the newtype declaration for ‘Duration’
......@@ -477,3 +477,4 @@ test('T15067', normal, compile_fail, [''])
test('T15330', normal, compile_fail, [''])
test('T15361', normal, compile_fail, [''])
test('T15438', normal, compile_fail, [''])
test('T15523', normal, compile_fail, ['-O'])
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment