Re: WinHugs beta

Neil Mitchell <[email protected]>
Newsgroups gmane.comp.lang.haskell.cvs.hugs
Message-ID <404396ef0510061126k5383c3b6j58c6b8ce4ed525c1__47195.1365158477$1128623242$gmane$org@mail.gmail.com>
> Under Unix, echoing is left to the OS.  The usual OS setting is to echo
> by characters.  I thought plain hugs running in a Windows console window
> did this too, but haven't checked.
It doesn't.

> So I'd prefer to have characters echoed as they're typed, but don't
> know what is the cleanest way to achieve this under WinHugs.
There are two solutions:

1) Add it to WinHugs, easy enough, just make the typed character
handler also write a character (currently it deliberately blocks it).
This won't fix it in command line hugs.

2) Add it to Hugs, on windows platform explicitly do a getchar,
putchar. WinHugs would receive this fix automatically because it traps
putchar.

As for line buffering, this should be something specified by the
standard. Lines can be buffered with a unlines . map (reverse .
reverse) . lines style construct, and this was how I was taught to use
interact with buffering.

Neil
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.