patch applied (hugs98): readline command completion (from Georg Sauthoff)

Ross Paterson <[email protected]> Sun, 1 Apr 2007 02:18:51 -0700
Newsgroups gmane.comp.lang.haskell.cvs.hugs
Message-ID <[email protected]>
Sun Apr  1 02:12:02 PDT 2007  Ross Paterson <[email protected]>
  * readline command completion (from Georg Sauthoff)
  
  Improves the readline command completion feature of hugs:
   - added completion of function names and constructors
   - added completion of command names (:<cmd>)
   - added completion of module names (e.g. after :browse , etc.)
   - only do filename completion where it makes sense (e.g. after :load , etc.)
   - expand use of tilde (~) in filenames (previously it was completed but not
     recognized by hugs)
   - read and write the history from/to ~/.hugs_history
   - make hugs recognize :help
  
  It's not perfect, e.g.:
   - the names include things that aren't in scope (:names has the same problem)
   - the names don't include qualified names
   - the words completed are space-delimited, rather than being Haskell ids
   - completion for :load works for filenames only, not modules
  Still, it's a start, and better than nothing.

    M ./src/hugs.c -6 +165
    M ./src/input.c -8 +16
    M ./src/storage.c -1 +1
    M ./src/storage.h +2