I'm developing a system using Hugs (and GHC) and Main.main is the
function that starts my whole system.

Suppose I'm testing local stuff in module Foo using Hugs:

    Foo> fooFun 42
    ...

and then I want to run the whole system.  Now I have to type:

    Foo> :m Main    -- or ":l Main" if Foo has changed
    Main> main

and if I need to test Foo some more after main terminates I have to go
back using ":m" again.

I suggest adding a command to Hugs that, from any module, calls
Main.main ((re)loading if necessary) and returns to the current module
scope after termination.  The command could be ":x" for e_x_ecute or
even ":" -- the shorter the better (considering the number of times I
type "main" these days :).

A generalisation would be to allow using qualified names to refer to
other modules than the current, but I'm not sure if this is really
useful.

Just a though,
  Bjarte

Reply via email to