Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
GHC
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Iterations
Merge Requests
0
Merge Requests
0
Requirements
Requirements
List
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Package Registry
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Travis Whitaker
GHC
Commits
9e4b981f
Commit
9e4b981f
authored
May 09, 2020
by
Ben Gamari
🐢
Committed by
Marge Bot
May 13, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
testsuite: Add testcase for #18129
parent
5d0f2445
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
53 additions
and
0 deletions
+53
-0
testsuite/tests/typecheck/should_compile/T18129.hs
testsuite/tests/typecheck/should_compile/T18129.hs
+52
-0
testsuite/tests/typecheck/should_compile/all.T
testsuite/tests/typecheck/should_compile/all.T
+1
-0
No files found.
testsuite/tests/typecheck/should_compile/T18129.hs
0 → 100644
View file @
9e4b981f
{-# LANGUAGE AllowAmbiguousTypes #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE GADTs #-}
{-# LANGUAGE KindSignatures #-}
{-# LANGUAGE PolyKinds #-}
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE ConstraintKinds #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE UndecidableInstances #-}
{-# LANGUAGE UndecidableSuperClasses #-}
module
T18129
where
import
Data.Kind
(
Constraint
)
import
Data.Proxy
(
Proxy
)
import
Data.Typeable
(
Typeable
)
-- First, `generics-sop` code, intact.
--
type
family
AllF
(
c
::
k
->
Constraint
)
(
xs
::
[
k
])
::
Constraint
where
AllF
_c
'
[]
=
()
AllF
c
(
x
'
:
xs
)
=
(
c
x
,
All
c
xs
)
class
(
AllF
c
xs
,
SListI
xs
)
=>
All
(
c
::
k
->
Constraint
)
(
xs
::
[
k
])
instance
All
c
'
[]
instance
(
c
x
,
All
c
xs
)
=>
All
c
(
x
'
:
xs
)
where
class
Top
x
instance
Top
x
type
SListI
=
All
Top
-- Next, user code, minimised.
--
data
GADT
=
forall
(
xs
::
[
*
])
(
a
::
*
)
.
(
Top
a
,
All
Typeable
xs
)
=>
GADT
withSomePipe'
::
GADT
->
(
forall
(
xs
::
[
*
])
.
(
Proxy
xs
->
GADT
)
->
GADT
)
->
GADT
withSomePipe'
GADT
f
=
f
(
const
GADT
)
testsuite/tests/typecheck/should_compile/all.T
View file @
9e4b981f
...
...
@@ -706,3 +706,4 @@ test('T18023', normal, compile, [''])
test
('
T18036
',
normal
,
compile
,
[''])
test
('
T18036a
',
normal
,
compile
,
[''])
test
('
T17873
',
normal
,
compile
,
[''])
test
('
T18129
',
expect_broken
(
18129
),
compile
,
[''])
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