[m-dev.] Utility for developers

Ralph Becket rafe at cs.mu.OZ.AU
Thu Jul 1 11:51:48 AEST 2004


A while ago I wrote a little program called termuses (it's currently in
~rafe/mercury/termuses/termuses.m) which has turned out to be very
useful when making changes to the compiler.

I just run `termuses *.m >termuses.out' in the directory I'm working in
and the result is information like this in termuses.out:

...
aString_to_bytecode/2:
        rl_code.m: 49 50 1818 1856

abort_on_exist_qvar/0:
        type_util.m: 1191 1201 1207 1238

abs_follow_vars/0:
        code_info.m: 91 568
        hlds_llds.m: 41 144 176 218 237 293
        var_locn.m: 50 314

abs_follow_vars/2:
        code_gen.m: 244
        code_info.m: 997
        follow_vars.m: 173 180 187 350 382 424
        hlds_llds.m: 41 628 631
        hlds_out.m: 1965
        store_alloc.m: 76
        var_locn.m: 447 2191
...

Every term in the .m files appears once followed by the list of files
where it appears, each followed by the list of line numbers, one for
each occurrence.

Would anybody else find this helpful?  If so, should I add it to
mercury/tools?

-- Ralph
--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to:       mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions:          mercury-developers-request at cs.mu.oz.au
--------------------------------------------------------------------------



More information about the developers mailing list