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

Backspace character in haskell-interactive-mode #51

Closed
cmears opened this issue May 30, 2012 · 5 comments
Closed

Backspace character in haskell-interactive-mode #51

cmears opened this issue May 30, 2012 · 5 comments
Assignees

Comments

@cmears
Copy link
Contributor

cmears commented May 30, 2012

QuickCheck uses backspace characters to make nice output while it is running tests. This does not work in haskell-interactive-mode:

λ> import Test.QuickCheck

λ> quickCheck (\xs -> reverse (reverse xs) == xs)
(0 tests)���������^H^H^H^H^H^H^H^H^H         ���������^H^H^H^H^H^H^H^H^H(1 test) [etc.]

I think the old inferior-haskell mode handles this properly, but I'm not sure how to fix it in the new interactive mode.

@chrisdone
Copy link
Member

QuickCheck wrongly assumes it's in a terminal. I can add specific support for this in the REPL, but it's basically not a terminal.

@cmears
Copy link
Contributor Author

cmears commented Jun 1, 2012

I think it's fair to say that QuickCheck is wrong here. On a related note, should hIsTerminalDevice stdout return True in the REPL? (It currently does return True, but QuickCheck doesn't seem to check it in any case.)

@ghost ghost assigned chrisdone Jun 2, 2012
@chrisdone
Copy link
Member

It shouldn't really. I don't see any way in launching it in Elisp to not launch it as a terminal. One could pipe it to cat, but highly inportable.

@ShaneDrury
Copy link

I don't mean to dredge up a 4 year old issue, but it can be fixed by adding

(add-hook 'haskell-mode-hook
       '(lambda ()
          (setq process-connection-type nil)))

to your .emacs file. From https://sites.google.com/site/haskell/notes/ghci610emacsmadness

@ivan-m
Copy link
Contributor

ivan-m commented Jul 7, 2016

@ShaneDrury are you sure it's relevant? That page says it doesn't apply as of 6.10.3.

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

4 participants