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,867
    • Issues 4,867
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
  • Merge requests 455
    • Merge requests 455
  • 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
  • #18558
Closed
Open
Created Aug 10, 2020 by Roland Senn@RolandSennDeveloper

GHCi Debugger hangs in nested break in an eta reduced function

Summary

GHCi hangs when setting a breakpoint in an eta reduced function and re-evaluating this function when the breakpoint is hit.

Steps to reproduce

Use the module Hang.hs:

module Hang where

foo :: Int -> Int
foo = bar

bar :: Int -> Int
bar n = 2 * n

Do the following steps:

ghci Hang.hs
:break foo
foo 1              -- Evaluate function foo. GHCi stops at breakpoint
foo 2              -- Re-evaluate function foo from the breakpoint

-> GHCi now hangs!

Expected behavior

GHCi should not hang, it should stop at a nested breakpoint

Note

When I remove the eta reduction in the function foo

foo :: Int -> Int
foo x = bar x

then everything works fine!

Environment

  • GHC version used: 7.10.3 - 8.10.2 and HEAD

Optional:

  • Operating System: Debian 9
  • System Architecture: x86-64
Edited Aug 10, 2020 by Roland Senn
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking