[m-rev.] for review: mmc --make, submodules and java

Peter Wang novalazy at gmail.com
Tue May 5 17:54:35 AEST 2009


2009/5/5 Julien Fischer <juliensf at csse.unimelb.edu.au>:
>> -:- import_module libs.globals.
>> -
>> :- import_module libs.compiler_util.
>> +:- import_module libs.globals.
>> :- import_module libs.handle_options.
>> :- import_module libs.options.
>> +:- import_module mdbcomp.prim_data.
>> +:- import_module ml_backend.                % XXX unwanted dependency
>> +:- import_module ml_backend.mlds_to_java.   % XXX unwanted dependency
>> :- import_module parse_tree.prog_util.
>> :- import_module parse_tree.source_file_map.
>
> I strongly suggest not (re)introducing this dependency.  The alternative,
> duplicating a little code, seems preferable in this case.  (You presumably
> can't factor out the name mangling code into the libs package because
> it depends on the mlds_sym_name type.)

It only used mlds_qual_kind, which only says if the initial letter should be
case flipped or not.  There should be no problem factoring it out.  It calls
prog_foreign.name_mangle though, so either it goes into parse_tree, or we
move name_mangle into libs as well.  I think libs is preferred.

I'm not sure what to call the modules.  Maybe:

  * libs.common_name_mangle

  * libs.java_name (would need to contain valid_java_symbol_name,
    java_is_keyword and similar)

Peter
--------------------------------------------------------------------------
mercury-reviews mailing list
Post messages to:       mercury-reviews at csse.unimelb.edu.au
Administrative Queries: owner-mercury-reviews at csse.unimelb.edu.au
Subscriptions:          mercury-reviews-request at csse.unimelb.edu.au
--------------------------------------------------------------------------



More information about the reviews mailing list