Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

debug: Quit on ctrl-D #1286

Open
langston-barrett opened this issue Feb 6, 2025 · 0 comments
Open

debug: Quit on ctrl-D #1286

langston-barrett opened this issue Feb 6, 2025 · 0 comments

Comments

@langston-barrett
Copy link
Contributor

From @RyanGlScott:

Many REPLs (including GHCi and Python's REPL) interpret Ctrl-D as EOF and quit in response. It would be handy if the Crucible debugger could do the same.

isocline doesn't make this entirely straightforward to accomplish. At first glance, readlineExMaybe seems like what we'd want, as that causes Ctrl-D to return Nothing instead of empty text. On the other hand, Ctrl-C also returns Nothing, and I doubt that we'd want the debugger to exit on Ctrl-C (neither GHCi nor Python do this). See also https://github.com/daanx/isocline/issues/16.isocline doesn't make this entirely straightforward to accomplish. At first glance, readlineExMaybe seems like what we'd want, as that causes Ctrl-D to return Nothing instead of empty text. On the other hand, Ctrl-C also returns Nothing, and I doubt that we'd want the debugger to exit on Ctrl-C (neither GHCi nor Python do this). See also daanx/isocline#16.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant