Ticket #4420 (closed bug: fixed)

Opened 3 years ago

Last modified 3 years ago

T3851 fails because of untouchable type variables and escaping skolems

Reported by: daniel.is.fischer Owned by:
Priority: normal Milestone:
Component: Test Suite Version: 7.1
Keywords: Cc:
Operating System: Unknown/Multiple Architecture: Unknown/Multiple
Type of failure: None/Unknown Difficulty:
Test Case: Blocked By:
Blocking: Related Tickets:

Description

=====> T3851(normal) 1990 of 2612 [0, 7, 0]
cd ./indexed-types/should_compile && '/home/dafis/Haskell/Hacking/testTree/bindisttest/install dir/bin/ghc' -fforce-recomp -dcore-lint -dcmm-lint -dno-debug-output -no-user-package-conf -rtsopts  -c T3851.hs    >T3851.comp.stderr 2>&1
Wrong exit code (expected 0 , actual 2 )
Stdout:

Stderr:

IndTypesPerfMerge.hs:90:5:
    Couldn't match type `a1' with `UnmergedLeft (MergerType a1 b1)'
    because a1 is untouchable
    inside the constraints (Merger (DiscardRightHead h1 t1 h2 t2),
                            t1 ~ UnmergedLeft (MergerType t1 t2),
                            t2 ~ UnmergedRight (MergerType t1 t2),
                            Mergeable t1 t2,
                            Merger (MergerType t1 t2))
      bound at the instance declaration
    In the instance declaration for `Merger
                                       (DiscardRightHead h1 t1 h2 t2)'

IndTypesPerfMerge.hs:90:5:
    Couldn't match type `b1' with `UnmergedRight (MergerType a1 b1)'
    because b1 is untouchable
    inside the constraints (Merger (DiscardRightHead h1 t1 h2 t2),
                            t1 ~ UnmergedLeft (MergerType t1 t2),
                            t2 ~ UnmergedRight (MergerType t1 t2),
                            Mergeable t1 t2,
                            Merger (MergerType t1 t2))
      bound at the instance declaration
    In the instance declaration for `Merger
                                       (DiscardRightHead h1 t1 h2 t2)'

IndTypesPerfMerge.hs:98:16:
    Couldn't match type `t1' with `UnmergedLeft (MergerType a1 b1)'
      `t1' is a rigid type variable bound by
           the instance declaration at IndTypesPerfMerge.hs:90:16
    In the pattern: h1 :* t1
    In an equation for `mkMerge':
        mkMerge _ (h1 :* t1) (h2 :* t2)
          = h1 :* mkMerge (merger t1 t2) t1 t2
    In the instance declaration for `Merger
                                       (DiscardRightHead h1 t1 h2 t2)'

IndTypesPerfMerge.hs:98:27:
    Couldn't match type `t2' with `UnmergedRight (MergerType a1 b1)'
      `t2' is a rigid type variable bound by
           the instance declaration at IndTypesPerfMerge.hs:90:19
    In the pattern: h2 :* t2
    In an equation for `mkMerge':
        mkMerge _ (h1 :* t1) (h2 :* t2)
          = h1 :* mkMerge (merger t1 t2) t1 t2
    In the instance declaration for `Merger
                                       (DiscardRightHead h1 t1 h2 t2)'

IndTypesPerfMerge.hs:101:5:
    Couldn't match type `a'
                   with `UnmergedLeft (MergerType a (h2 :* t2))'
      because these skolem type variables would escape: `h2', `t2'
    These skolems are bound by the instance declaration
    In the instance declaration for `Merger
                                       (LeftHeadFirst h1 t1 h2 t2)'

IndTypesPerfMerge.hs:109:16:
    Couldn't match type `t1'
                   with `UnmergedLeft (MergerType a (h2 :* t2))'
      `t1' is a rigid type variable bound by
           the instance declaration at IndTypesPerfMerge.hs:101:16
    In the pattern: h1 :* t1
    In an equation for `mkMerge':
        mkMerge _ (h1 :* t1) (h2 :* t2)
          = h1 :* mkMerge (merger t1 (h2 :* t2)) t1 (h2 :* t2)
    In the instance declaration for `Merger
                                       (LeftHeadFirst h1 t1 h2 t2)'

IndTypesPerfMerge.hs:112:5:
    Couldn't match type `b'
                   with `UnmergedRight (MergerType (h1 :* t1) b)'
      because these skolem type variables would escape: `h1', `t1'
    These skolems are bound by the instance declaration
    In the instance declaration for `Merger
                                       (RightHeadFirst h1 t1 h2 t2)'

IndTypesPerfMerge.hs:120:27:
    Couldn't match type `t2'
                   with `UnmergedRight (MergerType (h1 :* t1) b)'
      `t2' is a rigid type variable bound by
           the instance declaration at IndTypesPerfMerge.hs:112:27
    In the pattern: h2 :* t2
    In an equation for `mkMerge':
        mkMerge _ (h1 :* t1) (h2 :* t2)
          = h2 :* mkMerge (merger (h1 :* t1) t2) (h1 :* t1) t2
    In the instance declaration for `Merger
                                       (RightHeadFirst h1 t1 h2 t2)'
gmake[3]: *** [IndTypesPerf] Fehler 1

*** unexpected failure for IndTypesPerf(normal)

Change History

Changed 3 years ago by simonpj

Yes. This is the last remaining testsuite failure relating to the type checker. We're on it.

Changed 3 years ago by simonpj

  • status changed from new to merge

Fixed

Changed 3 years ago by igloo

  • status changed from merge to closed
  • resolution set to fixed

I'm assuming the appropriate patch got merged, as I think I've merged all the type-checker patches, and the test is passing in the 7.0 branch.

Note: See TracTickets for help on using tickets.