Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in / Register
  • GHC GHC
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 4,932
    • Issues 4,932
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
  • Merge requests 464
    • Merge requests 464
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Deployments
    • Deployments
    • Releases
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Glasgow Haskell Compiler
  • GHCGHC
  • Issues
  • #5783
Closed
Open
Created Jan 16, 2012 by reinerp@trac-reinerp

Data.Text.isPrefixOf fails to terminate

The function Data.Text.isPrefixOf fails to terminate with GHC 7.4-rc1, although it terminates with GHC-7.2. Reproduction instructions:

$ cd ghc-7.4.0.20111219
$ sudo make install
$ cabal -V
cabal-install version 0.10.2
using version 1.10.1.0 of the Cabal library 
$ cabal install text-0.11.1.12
$ cd /tmp
$ cat >Test.hs
import Data.Text
main = print (pack "A" `isPrefixOf` pack "AB")
$ runghc Test.hs
<program hangs on 100% CPU use, without producing any output>

Unfortunately, it appears to be rather difficult to create a reduced test case; the problem disappears when I make any attempt to minimize it.

I have verified this on Mac OS X 10.7.2 and 64-bit Ubuntu 10.10.

Trac metadata
Trac field Value
Version 7.4.1-rc1
Type Bug
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component Compiler
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system
Architecture
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking