[m-rev.] diff: module imports
Zoltan Somogyi
zs at cs.mu.OZ.AU
Sat Mar 15 14:05:10 AEDT 2003
This diff doesn't change any functionality, and it is really boring.
Zoltan.
compiler/*.m:
Import only one compiler module per line. Sort the blocks of imports.
This makes it easier to merge in changes.
In a couple of places, remove unnecessary imports.
cvs diff: Diffing .
cvs diff: Diffing analysis
cvs diff: Diffing bindist
cvs diff: Diffing boehm_gc
cvs diff: Diffing boehm_gc/Mac_files
cvs diff: Diffing boehm_gc/cord
cvs diff: Diffing boehm_gc/cord/private
cvs diff: Diffing boehm_gc/doc
cvs diff: Diffing boehm_gc/include
cvs diff: Diffing boehm_gc/include/private
cvs diff: Diffing boehm_gc/tests
cvs diff: Diffing browser
cvs diff: Diffing bytecode
cvs diff: Diffing compiler
Index: compiler/accumulator.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/accumulator.m,v
retrieving revision 1.21
diff -u -b -r1.21 accumulator.m
--- compiler/accumulator.m 28 Feb 2003 00:21:36 -0000 1.21
+++ compiler/accumulator.m 14 Mar 2003 10:26:14 -0000
@@ -129,7 +129,9 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, io.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module io.
:- pred accumulator__process_proc(pred_id::in, proc_id::in, proc_info::in,
proc_info::out, module_info::in, module_info::out,
@@ -140,14 +142,22 @@
:- implementation.
-:- import_module (hlds__assertion), hlds__error_util.
-:- import_module transform_hlds__goal_store, hlds__goal_util, libs__globals.
-:- import_module hlds__hlds_data, hlds__hlds_goal, hlds__hlds_out.
-:- import_module (parse_tree__inst).
-:- import_module check_hlds__inst_match, hlds__instmap, check_hlds__mode_util.
-:- import_module libs__options.
-:- import_module parse_tree__prog_data, parse_tree__prog_util.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module hlds__assertion.
+:- import_module hlds__error_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_out.
+:- import_module hlds__instmap.
:- import_module hlds__quantification.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_util.
+:- import_module transform_hlds__goal_store.
:- import_module assoc_list, bool, int, list, map, multi_map.
:- import_module require, set, std_util, string, term, varset.
Index: compiler/add_heap_ops.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/add_heap_ops.m,v
retrieving revision 1.6
diff -u -b -r1.6 add_heap_ops.m
--- compiler/add_heap_ops.m 1 Nov 2002 07:06:55 -0000 1.6
+++ compiler/add_heap_ops.m 14 Mar 2003 08:41:05 -0000
@@ -29,7 +29,9 @@
:- module ml_backend__add_heap_ops.
:- interface.
-:- import_module hlds__hlds_pred, hlds__hlds_module.
+
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- pred add_heap_ops(proc_info::in, module_info::in, proc_info::out) is det.
@@ -37,17 +39,21 @@
:- implementation.
-:- import_module parse_tree__prog_data, parse_tree__prog_util.
-:- import_module (parse_tree__inst).
-:- import_module hlds__hlds_goal, hlds__hlds_data.
-:- import_module hlds__goal_util, hlds__quantification, parse_tree__modules.
+:- import_module backend_libs__code_model.
:- import_module check_hlds__type_util.
-:- import_module hlds__instmap, backend_libs__code_model.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__instmap.
+:- import_module hlds__quantification.
:- import_module ll_backend__code_util.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_util.
:- import_module bool, string.
:- import_module assoc_list, list, map, set, varset, std_util, require, term.
-
%
% As we traverse the goal, we add new variables to hold the
Index: compiler/add_trail_ops.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/add_trail_ops.m,v
retrieving revision 1.9
diff -u -b -r1.9 add_trail_ops.m
--- compiler/add_trail_ops.m 1 Nov 2002 07:06:55 -0000 1.9
+++ compiler/add_trail_ops.m 14 Mar 2003 08:41:31 -0000
@@ -29,7 +29,9 @@
:- module ml_backend__add_trail_ops.
:- interface.
-:- import_module hlds__hlds_pred, hlds__hlds_module.
+
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- pred add_trail_ops(proc_info::in, module_info::in, proc_info::out) is det.
@@ -37,16 +39,20 @@
:- implementation.
-:- import_module parse_tree__prog_data, parse_tree__prog_util.
-:- import_module (parse_tree__inst).
-:- import_module hlds__hlds_goal, hlds__hlds_data.
-:- import_module hlds__goal_util, hlds__quantification, parse_tree__modules.
+:- import_module backend_libs__code_model.
:- import_module check_hlds__type_util.
-:- import_module backend_libs__code_model, hlds__instmap.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__instmap.
+:- import_module hlds__quantification.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_util.
:- import_module bool, string.
:- import_module assoc_list, list, map, set, varset, std_util, require, term.
-
%
% As we traverse the goal, we add new variables to hold the
Index: compiler/aditi_backend.pp
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/aditi_backend.pp,v
retrieving revision 1.1
diff -u -b -r1.1 aditi_backend.pp
--- compiler/aditi_backend.pp 26 Jul 2002 09:06:49 -0000 1.1
+++ compiler/aditi_backend.pp 14 Mar 2003 15:37:36 -0000
@@ -19,8 +19,9 @@
%:- module aditi_hlds.
% :- interface.
:- include_module dnf.
- :- include_module magic, magic_util.
:- include_module context.
+ :- include_module magic.
+ :- include_module magic_util.
%:- end_module aditi_hlds.
%
@@ -43,17 +44,25 @@
% Phase 6-rl: Low-level (RL -> RL) optimizations
%
:- include_module rl_opt.
- :- include_module rl_block, rl_analyse, rl_liveness, rl_loop, rl_block_opt.
- :- include_module rl_key, rl_sort, rl_stream.
+ :- include_module rl_analyse.
+ :- include_module rl_block.
+ :- include_module rl_block_opt.
+ :- include_module rl_key.
+ :- include_module rl_liveness.
+ :- include_module rl_loop.
+ :- include_module rl_sort.
+ :- include_module rl_stream.
%
% Phase 7-rl: Emit RL bytecodes.
%
%:- module aditi_rl_out.
- :- include_module rl_out, rl_file.
+ :- include_module rl_out.
+ :- include_module rl_file.
#if INCLUDE_ADITI_OUTPUT
- :- include_module rl_exprn, rl_code.
+ :- include_module rl_exprn.
+ :- include_module rl_code.
#else
#endif
Index: compiler/arg_info.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/arg_info.m,v
retrieving revision 1.38
diff -u -b -r1.38 arg_info.m
--- compiler/arg_info.m 30 May 2002 12:54:55 -0000 1.38
+++ compiler/arg_info.m 14 Mar 2003 08:43:18 -0000
@@ -17,8 +17,13 @@
:- module ll_backend__arg_info.
:- interface.
-:- import_module parse_tree__prog_data, hlds__hlds_module, hlds__hlds_pred.
-:- import_module backend_libs__code_model, ll_backend__llds.
+
+:- import_module backend_libs__code_model.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__prog_data.
+
:- import_module list, assoc_list, set.
% Annotate every non-aditi procedure in the module with information
@@ -95,7 +100,9 @@
:- implementation.
-:- import_module ll_backend__code_util, check_hlds__mode_util.
+:- import_module check_hlds__mode_util.
+:- import_module ll_backend__code_util.
+
:- import_module std_util, map, int, require.
%-----------------------------------------------------------------------------%
Index: compiler/assertion.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/assertion.m,v
retrieving revision 1.21
diff -u -b -r1.21 assertion.m
--- compiler/assertion.m 27 Jan 2003 09:20:44 -0000 1.21
+++ compiler/assertion.m 14 Mar 2003 08:43:36 -0000
@@ -18,8 +18,12 @@
:- interface.
-:- import_module hlds__hlds_data, hlds__hlds_goal, hlds__hlds_module.
-:- import_module hlds__hlds_pred, parse_tree__prog_data.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
+
:- import_module io, std_util.
%
@@ -140,9 +144,14 @@
:- implementation.
-:- import_module libs__globals, hlds__goal_util, hlds__hlds_out.
-:- import_module libs__options, parse_tree__prog_out, parse_tree__prog_util.
:- import_module check_hlds__type_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_out.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
+
:- import_module assoc_list, bool, list, map, require, set, std_util.
:- type subst == map(prog_var, prog_var).
Index: compiler/base_typeclass_info.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/base_typeclass_info.m,v
retrieving revision 1.22
diff -u -b -r1.22 base_typeclass_info.m
--- compiler/base_typeclass_info.m 14 Mar 2003 08:10:04 -0000 1.22
+++ compiler/base_typeclass_info.m 14 Mar 2003 08:44:42 -0000
@@ -20,9 +20,12 @@
:- interface.
-:- import_module hlds__hlds_module, list, backend_libs__rtti.
+:- import_module backend_libs__rtti.
+:- import_module hlds__hlds_module.
:- import_module parse_tree__prog_data.
+:- import_module list.
+
:- pred base_typeclass_info__generate_rtti(module_info, list(rtti_data)).
:- mode base_typeclass_info__generate_rtti(in, out) is det.
@@ -34,11 +37,17 @@
:- implementation.
-:- import_module parse_tree__prog_io, parse_tree__prog_out.
-:- import_module hlds__hlds_data, hlds__hlds_pred, hlds__hlds_out.
-:- import_module ll_backend__code_util, libs__globals, libs__options, term.
-:- import_module bool, string, map, std_util, require, assoc_list.
-:- import_module check_hlds__type_util, int.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_out.
+:- import_module hlds__hlds_pred.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ll_backend__code_util.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_out.
+
+:- import_module bool, int, string, map, std_util, require, term, assoc_list.
%---------------------------------------------------------------------------%
Index: compiler/builtin_ops.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/builtin_ops.m,v
retrieving revision 1.11
diff -u -b -r1.11 builtin_ops.m
--- compiler/builtin_ops.m 20 Mar 2002 12:35:51 -0000 1.11
+++ compiler/builtin_ops.m 14 Mar 2003 08:45:05 -0000
@@ -16,9 +16,11 @@
:- module backend_libs__builtin_ops.
:- interface.
-:- import_module parse_tree__prog_data, hlds__hlds_pred.
-:- import_module list.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
+
+:- import_module list.
:- type unary_op
---> mktag
Index: compiler/bytecode.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/bytecode.m,v
retrieving revision 1.51
diff -u -b -r1.51 bytecode.m
--- compiler/bytecode.m 10 Jan 2003 05:10:30 -0000 1.51
+++ compiler/bytecode.m 14 Mar 2003 08:45:25 -0000
@@ -14,8 +14,11 @@
:- interface.
-:- import_module hlds__hlds_data, parse_tree__prog_data, libs__tree.
:- import_module backend_libs__builtin_ops.
+:- import_module hlds__hlds_data.
+:- import_module libs__tree.
+:- import_module parse_tree__prog_data.
+
:- import_module char, list, std_util, io.
:- type byte_tree == tree(list(byte_code)).
@@ -138,8 +141,11 @@
:- implementation.
-:- import_module backend_libs__bytecode_data, hlds__hlds_pred.
-:- import_module parse_tree__prog_out, backend_libs__c_util.
+:- import_module backend_libs__bytecode_data.
+:- import_module backend_libs__c_util.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_out.
+
:- import_module library, int, string, require.
:- pred bytecode__version(int::out) is det.
Index: compiler/bytecode_backend.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/bytecode_backend.m,v
retrieving revision 1.1
diff -u -b -r1.1 bytecode_backend.m
--- compiler/bytecode_backend.m 20 Mar 2002 12:35:52 -0000 1.1
+++ compiler/bytecode_backend.m 14 Mar 2003 08:46:12 -0000
@@ -11,12 +11,18 @@
%
:- module bytecode_backend.
:- interface.
-:- import_module transform_hlds, check_hlds. % are these needed?
-:- import_module hlds, parse_tree, libs, backend_libs.
+
+:- import_module backend_libs.
+:- import_module check_hlds. % is this needed?
+:- import_module hlds.
+:- import_module libs.
+:- import_module parse_tree.
+:- import_module transform_hlds. % is this needed?
%-----------------------------------------------------------------------------%
-:- include_module bytecode, bytecode_gen.
+:- include_module bytecode.
+:- include_module bytecode_gen.
%-----------------------------------------------------------------------------%
Index: compiler/bytecode_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/bytecode_gen.m,v
retrieving revision 1.70
diff -u -b -r1.70 bytecode_gen.m
--- compiler/bytecode_gen.m 27 Jan 2003 09:20:44 -0000 1.70
+++ compiler/bytecode_gen.m 14 Mar 2003 08:47:01 -0000
@@ -15,7 +15,9 @@
:- interface.
-:- import_module hlds__hlds_module, bytecode_backend__bytecode.
+:- import_module bytecode_backend__bytecode.
+:- import_module hlds__hlds_module.
+
:- import_module io, list.
:- pred bytecode_gen__module(module_info::in, list(byte_code)::out,
@@ -36,16 +38,22 @@
% in call_gen.m that we use here into arg_info.m, and to then rework
% arg_info.m so that it didn't depend on the LLDS.
+:- import_module backend_libs__builtin_ops.
+:- import_module backend_libs__code_model.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__tree.
:- import_module ll_backend__arg_info.
:- import_module ll_backend__call_gen. % XXX for arg passing convention
:- import_module ll_backend__code_util. % XXX for cons_id_to_tag
-
:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_pred, hlds__hlds_goal, hlds__hlds_data.
-:- import_module check_hlds__type_util, check_hlds__mode_util, hlds__goal_util.
-:- import_module backend_libs__builtin_ops, backend_libs__code_model.
-:- import_module hlds__passes_aux, hlds__error_util.
-:- import_module libs__globals, libs__tree.
:- import_module parse_tree__prog_out.
:- import_module bool, int, string, list, assoc_list, set, map, varset.
Index: compiler/c_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/c_util.m,v
retrieving revision 1.13
diff -u -b -r1.13 c_util.m
--- compiler/c_util.m 15 Mar 2003 00:08:51 -0000 1.13
+++ compiler/c_util.m 15 Mar 2003 02:54:25 -0000
@@ -17,8 +17,9 @@
:- module backend_libs__c_util.
:- interface.
-:- import_module io, char, string, int.
+
:- import_module backend_libs__builtin_ops.
+:- import_module io, char, string, int.
%-----------------------------------------------------------------------------%
%
@@ -137,7 +138,10 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module libs__globals, libs__options.
+
+:- import_module libs__globals.
+:- import_module libs__options.
+
:- import_module list, bool.
%-----------------------------------------------------------------------------%
Index: compiler/call_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/call_gen.m,v
retrieving revision 1.152
diff -u -b -r1.152 call_gen.m
--- compiler/call_gen.m 27 Jan 2003 09:20:44 -0000 1.152
+++ compiler/call_gen.m 14 Mar 2003 08:47:45 -0000
@@ -18,9 +18,13 @@
:- interface.
-:- import_module parse_tree__prog_data, hlds__hlds_pred, hlds__hlds_goal.
-:- import_module backend_libs__code_model, ll_backend__llds.
+:- import_module backend_libs__code_model.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_pred.
:- import_module ll_backend__code_info.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__prog_data.
+
:- import_module list, assoc_list.
:- pred call_gen__generate_call(code_model::in, pred_id::in, proc_id::in,
@@ -55,14 +59,22 @@
:- implementation.
-:- import_module hlds__hlds_module, hlds__hlds_data, hlds__hlds_llds.
-:- import_module check_hlds__polymorphism, check_hlds__type_util.
-:- import_module check_hlds__mode_util, check_hlds__unify_proc, hlds__instmap.
-:- import_module ll_backend__arg_info, ll_backend__code_util.
-:- import_module ll_backend__trace.
:- import_module aditi_backend__rl.
:- import_module backend_libs__builtin_ops.
-:- import_module libs__globals, libs__options, libs__tree.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__polymorphism.
+:- import_module check_hlds__type_util.
+:- import_module check_hlds__unify_proc.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_llds.
+:- import_module hlds__hlds_module.
+:- import_module hlds__instmap.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__tree.
+:- import_module ll_backend__arg_info.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__trace.
:- import_module bool, int, string, map, set, std_util, require, varset.
Index: compiler/check_hlds.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/check_hlds.m,v
retrieving revision 1.1
diff -u -b -r1.1 check_hlds.m
--- compiler/check_hlds.m 20 Mar 2002 12:35:53 -0000 1.1
+++ compiler/check_hlds.m 14 Mar 2003 08:49:23 -0000
@@ -10,41 +10,59 @@
:- module check_hlds.
:- interface.
-:- import_module hlds, parse_tree, libs.
+
+:- import_module hlds.
+:- import_module parse_tree.
+:- import_module libs.
:- import_module backend_libs. % for base_typeclass_info, etc.
-%:- import_module check_hlds__type_analysis, check_hlds__mode_analysis.
+
+% :- import_module check_hlds__type_analysis.
+% :- import_module check_hlds__mode_analysis.
%-----------------------------------------------------------------------------%
% Type checking
%:- module type_analysis.
- :- include_module check_typeclass, typecheck, purity, post_typecheck.
+ :- include_module check_typeclass.
+ :- include_module post_typecheck.
+ :- include_module purity.
:- include_module type_util.
+ :- include_module typecheck.
%:- end_module type_analysis.
% Polymorphism transformation.
-:- include_module polymorphism.
:- include_module clause_to_proc.
+:- include_module polymorphism.
% Mode analysis
%:- module mode_analysis.
- :- include_module modes, modecheck_unify, modecheck_call.
- :- include_module mode_info, delay_info, inst_match.
- :- include_module inst_util, mode_errors, mode_util, mode_debug.
- :- include_module unique_modes.
+ :- include_module delay_info.
+ :- include_module inst_match.
+ :- include_module inst_util.
+ :- include_module mode_debug.
+ :- include_module mode_errors.
+ :- include_module mode_info.
+ :- include_module mode_util.
+ :- include_module modecheck_call.
+ :- include_module modecheck_unify.
+ :- include_module modes.
:- include_module unify_proc.
+ :- include_module unique_modes.
%:- end_module mode_analysis.
% Indexing and determinism analysis
-:- include_module switch_detection, cse_detection, det_analysis.
-:- include_module det_report, det_util.
+:- include_module cse_detection.
+:- include_module det_analysis.
+:- include_module det_report.
+:- include_module det_util.
+:- include_module switch_detection.
% Stratification.
:- include_module stratify.
% Warnings about simple code
-:- include_module simplify.
:- include_module common.
+:- include_module simplify.
:- include_module goal_path.
Index: compiler/check_typeclass.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/check_typeclass.m,v
retrieving revision 1.47
diff -u -b -r1.47 check_typeclass.m
--- compiler/check_typeclass.m 22 Feb 2003 13:18:22 -0000 1.47
+++ compiler/check_typeclass.m 14 Mar 2003 08:49:45 -0000
@@ -46,10 +46,11 @@
:- module check_hlds__check_typeclass.
-
:- interface.
-:- import_module hlds__hlds_module, hlds__make_hlds.
+:- import_module hlds__hlds_module.
+:- import_module hlds__make_hlds.
+
:- import_module bool, io.
:- pred check_typeclass__check_instance_decls(module_info, qual_info,
@@ -59,15 +60,22 @@
:- implementation.
-:- import_module parse_tree__prog_data, parse_tree__prog_out.
-:- import_module parse_tree__prog_util.
-:- import_module hlds__hlds_pred, hlds__hlds_data, hlds__hlds_goal.
-:- import_module hlds__hlds_out.
-:- import_module check_hlds__type_util, check_hlds__typecheck.
-:- import_module check_hlds__mode_util, check_hlds__inst_match.
:- import_module backend_libs__base_typeclass_info.
-:- import_module parse_tree__mercury_to_mercury, hlds__error_util.
-:- import_module libs__globals, libs__options.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module check_hlds__typecheck.
+:- import_module hlds__error_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_out.
+:- import_module hlds__hlds_pred.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
:- import_module int, string.
:- import_module list, assoc_list, map, set, term, varset.
Index: compiler/clause_to_proc.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/clause_to_proc.m,v
retrieving revision 1.34
diff -u -b -r1.34 clause_to_proc.m
--- compiler/clause_to_proc.m 5 Jun 2002 16:41:12 -0000 1.34
+++ compiler/clause_to_proc.m 14 Mar 2003 08:50:02 -0000
@@ -8,7 +8,9 @@
:- interface.
-:- import_module hlds__hlds_pred, hlds__hlds_module.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+
:- import_module list, std_util.
% In the hlds, we initially record the clauses for a predicate
@@ -48,9 +50,14 @@
:- implementation.
-:- import_module hlds__hlds_goal, hlds__hlds_data, parse_tree__prog_data.
-:- import_module check_hlds__mode_util, hlds__make_hlds, check_hlds__purity.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__purity.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__make_hlds.
:- import_module libs__globals.
+:- import_module parse_tree__prog_data.
+
:- import_module assoc_list, bool, int, set, map, varset.
maybe_add_default_func_modes([], Preds, Preds).
Index: compiler/code_aux.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/code_aux.m,v
retrieving revision 1.65
diff -u -b -r1.65 code_aux.m
--- compiler/code_aux.m 28 Mar 2002 03:42:43 -0000 1.65
+++ compiler/code_aux.m 14 Mar 2003 08:50:18 -0000
@@ -15,9 +15,11 @@
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_goal, hlds__hlds_llds.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_llds.
:- import_module ll_backend__code_info.
+:- import_module parse_tree__prog_data.
+
:- import_module bool.
% code_aux__contains_simple_recursive_call(G, CI, Last) succeeds
@@ -39,7 +41,9 @@
:- implementation.
:- import_module hlds__goal_form.
-:- import_module ll_backend__llds, ll_backend__llds_out.
+:- import_module ll_backend__llds.
+:- import_module ll_backend__llds_out.
+
:- import_module string, list, assoc_list, map, std_util, varset.
%-----------------------------------------------------------------------------%
Index: compiler/code_exprn.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/code_exprn.m,v
retrieving revision 1.65
diff -u -b -r1.65 code_exprn.m
--- compiler/code_exprn.m 28 Mar 2002 03:42:43 -0000 1.65
+++ compiler/code_exprn.m 14 Mar 2003 08:50:41 -0000
@@ -36,9 +36,11 @@
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_llds, ll_backend__llds.
+:- import_module hlds__hlds_llds.
:- import_module libs__options.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__prog_data.
+
:- import_module map, set, list, assoc_list.
:- type exprn_info.
@@ -256,7 +258,10 @@
:- implementation.
-:- import_module ll_backend__code_util, ll_backend__exprn_aux, libs__tree.
+:- import_module libs__tree.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__exprn_aux.
+
:- import_module varset, term.
:- import_module bool, bag, require, int, string, std_util.
Index: compiler/code_model.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/code_model.m,v
retrieving revision 1.2
diff -u -b -r1.2 code_model.m
--- compiler/code_model.m 20 Mar 2002 12:35:59 -0000 1.2
+++ compiler/code_model.m 14 Mar 2003 08:51:06 -0000
@@ -20,8 +20,10 @@
%-----------------------------------------------------------------------------%
:- interface.
+
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_pred.
:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_pred, hlds__hlds_goal.
:- type code_model
---> model_det % functional & total
Index: compiler/commit_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/commit_gen.m,v
retrieving revision 1.3
diff -u -b -r1.3 commit_gen.m
--- compiler/commit_gen.m 20 Mar 2002 12:35:59 -0000 1.3
+++ compiler/commit_gen.m 14 Mar 2003 08:51:28 -0000
@@ -16,15 +16,19 @@
:- interface.
-:- import_module hlds__hlds_goal, backend_libs__code_model, ll_backend__llds.
+:- import_module backend_libs__code_model.
+:- import_module hlds__hlds_goal.
:- import_module ll_backend__code_info.
+:- import_module ll_backend__llds.
:- pred commit_gen__generate_commit(code_model::in, hlds_goal::in,
code_tree::out, code_info::in, code_info::out) is det.
:- implementation.
-:- import_module ll_backend__code_gen, libs__tree.
+:- import_module libs__tree.
+:- import_module ll_backend__code_gen.
+
:- import_module std_util, require.
commit_gen__generate_commit(OuterCodeModel, Goal, Code) -->
Index: compiler/common.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/common.m,v
retrieving revision 1.67
diff -u -b -r1.67 common.m
--- compiler/common.m 28 Feb 2003 00:21:36 -0000 1.67
+++ compiler/common.m 14 Mar 2003 08:51:58 -0000
@@ -29,8 +29,11 @@
:- module check_hlds__common.
:- interface.
-:- import_module hlds__hlds_pred, hlds__hlds_goal, parse_tree__prog_data.
:- import_module check_hlds__simplify.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
+
:- import_module list.
% If we find a deconstruction or a construction we cannot optimize,
@@ -81,13 +84,22 @@
:- implementation.
-:- import_module hlds__quantification, check_hlds__mode_util.
-:- import_module check_hlds__type_util, parse_tree__prog_util.
-:- import_module check_hlds__det_util, check_hlds__det_report, libs__globals.
-:- import_module libs__options, check_hlds__inst_match, hlds__instmap.
-:- import_module hlds__hlds_data, hlds__hlds_module, (parse_tree__inst).
-:- import_module transform_hlds__pd_cost.
+:- import_module check_hlds__det_report.
+:- import_module check_hlds__det_util.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__instmap.
+:- import_module hlds__quantification.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_util.
+:- import_module transform_hlds__pd_cost.
+
:- import_module bool, map, set, eqvclass, require, std_util, string, term.
:- type structure
Index: compiler/compile_target_code.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/compile_target_code.m,v
retrieving revision 1.41
diff -u -b -r1.41 compile_target_code.m
--- compiler/compile_target_code.m 12 Mar 2003 08:01:46 -0000 1.41
+++ compiler/compile_target_code.m 14 Mar 2003 08:52:39 -0000
@@ -13,7 +13,8 @@
:- interface.
-:- import_module parse_tree__prog_data, parse_tree__prog_io.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_io.
:- import_module parse_tree__modules.
:- import_module libs__globals.
@@ -165,13 +166,16 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module libs__globals, libs__options, libs__handle_options.
-:- import_module hlds__error_util, hlds__passes_aux, libs__trace_params.
-:- import_module parse_tree__prog_out.
:- import_module backend_libs__foreign.
-
+:- import_module hlds__error_util.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__handle_options.
+:- import_module libs__options.
+:- import_module libs__trace_params.
:- import_module ll_backend__llds_out. % for llds_out__make_init_name and
% llds_out__make_rl_data_name
+:- import_module parse_tree__prog_out.
:- import_module char, dir, getopt, int, require, string.
Index: compiler/const_prop.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/const_prop.m,v
retrieving revision 1.16
diff -u -b -r1.16 const_prop.m
--- compiler/const_prop.m 10 Jan 2003 10:40:52 -0000 1.16
+++ compiler/const_prop.m 14 Mar 2003 08:53:11 -0000
@@ -31,17 +31,28 @@
:- implementation.
-:- import_module ll_backend__code_aux, check_hlds__det_analysis.
-:- import_module ll_backend__follow_code, hlds__goal_util.
-:- import_module hlds__hlds_goal, hlds__hlds_data, hlds__instmap.
+:- import_module check_hlds__det_analysis.
:- import_module check_hlds__inst_match.
-:- import_module libs__globals, libs__options, hlds__passes_aux.
-:- import_module parse_tree__prog_data, check_hlds__mode_util.
-:- import_module check_hlds__type_util.
-:- import_module ll_backend__code_util, hlds__quantification.
+:- import_module check_hlds__mode_util.
:- import_module check_hlds__modes.
+:- import_module check_hlds__type_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_out.
+:- import_module hlds__instmap.
+:- import_module hlds__passes_aux.
+:- import_module hlds__quantification.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ll_backend__code_aux.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__follow_code.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+
:- import_module bool, list, int, float, map, require.
-:- import_module (parse_tree__inst), hlds__hlds_out, std_util.
+:- import_module std_util.
%------------------------------------------------------------------------------%
Index: compiler/constraint.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/constraint.m,v
retrieving revision 1.50
diff -u -b -r1.50 constraint.m
--- compiler/constraint.m 28 Feb 2003 00:21:36 -0000 1.50
+++ compiler/constraint.m 14 Mar 2003 08:53:31 -0000
@@ -17,8 +17,11 @@
:- interface.
-:- import_module hlds__hlds_goal, hlds__hlds_module, hlds__instmap.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__instmap.
:- import_module parse_tree__prog_data.
+
:- import_module bool, map.
:- type constraint_info.
@@ -45,12 +48,17 @@
:- implementation.
-:- import_module hlds__goal_util, hlds__hlds_pred, hlds__hlds_module.
-:- import_module hlds__hlds_data, hlds__passes_aux, hlds__goal_form.
-:- import_module check_hlds__purity.
-:- import_module check_hlds__mode_util.
:- import_module check_hlds__inst_match.
-:- import_module libs__options, libs__globals.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__purity.
+:- import_module hlds__goal_form.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
:- import_module assoc_list, list, require, set, std_util.
:- import_module string, term, varset.
Index: compiler/context.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/context.m,v
retrieving revision 1.6
diff -u -b -r1.6 context.m
--- compiler/context.m 28 Feb 2003 00:21:36 -0000 1.6
+++ compiler/context.m 14 Mar 2003 08:53:54 -0000
@@ -30,8 +30,11 @@
:- interface.
-:- import_module hlds__hlds_goal, hlds__hlds_pred, aditi_backend__magic_util.
+:- import_module aditi_backend__magic_util.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_pred.
:- import_module parse_tree__prog_data.
+
:- import_module list.
% context__process_disjuncts(OrigPredProcId, Inputs, Outputs,
@@ -48,9 +51,12 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module hlds__hlds_data, hlds__hlds_module, (parse_tree__inst).
-:- import_module hlds__instmap.
:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__instmap.
+:- import_module parse_tree__inst.
+
:- import_module assoc_list, bool, map, require, set, std_util, term, varset.
context__process_disjuncts(OldPredProcId, Inputs, Outputs,
Index: compiler/continuation_info.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/continuation_info.m,v
retrieving revision 1.46
diff -u -b -r1.46 continuation_info.m
--- compiler/continuation_info.m 27 Jan 2003 09:20:44 -0000 1.46
+++ compiler/continuation_info.m 14 Mar 2003 08:54:27 -0000
@@ -51,10 +51,17 @@
:- interface.
-:- import_module ll_backend__llds, hlds__hlds_module, hlds__hlds_pred.
-:- import_module hlds__hlds_goal, parse_tree__prog_data.
-:- import_module (parse_tree__inst), hlds__instmap, ll_backend__trace.
-:- import_module backend_libs__rtti, libs__globals.
+:- import_module backend_libs__rtti.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module libs__globals.
+:- import_module ll_backend__llds.
+:- import_module ll_backend__trace.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+
:- import_module bool, std_util, list, assoc_list, set, map.
%
@@ -332,10 +339,12 @@
:- implementation.
-:- import_module hlds__hlds_goal, hlds__hlds_llds.
-:- import_module check_hlds__type_util, check_hlds__inst_match.
-:- import_module ll_backend__code_util.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_llds.
:- import_module libs__options.
+:- import_module ll_backend__code_util.
:- import_module string, require, term, varset.
Index: compiler/cse_detection.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/cse_detection.m,v
retrieving revision 1.74
diff -u -b -r1.74 cse_detection.m
--- compiler/cse_detection.m 27 Jan 2003 09:20:44 -0000 1.74
+++ compiler/cse_detection.m 14 Mar 2003 08:54:49 -0000
@@ -18,7 +18,10 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, io.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+
+:- import_module io.
:- pred detect_cse(module_info::in, module_info::out,
io__state::di, io__state::uo) is det.
@@ -32,14 +35,24 @@
:- implementation.
-:- import_module hlds__hlds_goal, hlds__hlds_data, libs__options.
-:- import_module libs__globals, hlds__goal_util, hlds__hlds_out.
-:- import_module check_hlds__type_util, check_hlds__modes.
-:- import_module check_hlds__mode_util, hlds__quantification, hlds__instmap.
-:- import_module parse_tree__prog_data, check_hlds__switch_detection.
-:- import_module check_hlds__det_util, check_hlds__inst_match.
-:- import_module check_hlds__switch_detection, term, varset.
+:- import_module check_hlds__det_util.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__modes.
+:- import_module check_hlds__switch_detection.
+:- import_module check_hlds__switch_detection.
+:- import_module check_hlds__type_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_out.
+:- import_module hlds__instmap.
+:- import_module hlds__quantification.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__prog_data.
+:- import_module term, varset.
:- import_module int, bool, list, assoc_list, map, multi_map.
:- import_module set, std_util, require.
Index: compiler/dead_proc_elim.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/dead_proc_elim.m,v
retrieving revision 1.77
diff -u -b -r1.77 dead_proc_elim.m
--- compiler/dead_proc_elim.m 10 Mar 2003 14:10:53 -0000 1.77
+++ compiler/dead_proc_elim.m 14 Mar 2003 08:55:23 -0000
@@ -18,7 +18,10 @@
:- interface.
-:- import_module parse_tree__prog_data, hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
+
:- import_module map, std_util, io.
:- pred dead_proc_elim(module_info, module_info, io__state, io__state).
@@ -50,9 +53,13 @@
:- implementation.
-:- import_module hlds__hlds_goal, hlds__hlds_data, parse_tree__prog_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
:- import_module ll_backend__llds.
-:- import_module hlds__passes_aux, libs__globals, libs__options.
+:- import_module parse_tree__prog_util.
:- import_module int, string, list, set, queue, bool, require.
Index: compiler/deep_profiling.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/deep_profiling.m,v
retrieving revision 1.16
diff -u -b -r1.16 deep_profiling.m
--- compiler/deep_profiling.m 14 Mar 2003 08:10:05 -0000 1.16
+++ compiler/deep_profiling.m 14 Mar 2003 08:55:45 -0000
@@ -16,7 +16,9 @@
:- interface.
-:- import_module hlds__hlds_module, ll_backend__layout.
+:- import_module hlds__hlds_module.
+:- import_module ll_backend__layout.
+
:- import_module io, list.
:- pred apply_deep_profiling_transformation(module_info::in, module_info::out,
@@ -26,14 +28,24 @@
:- implementation.
-:- import_module (parse_tree__inst), hlds__instmap, hlds__hlds_data.
-:- import_module hlds__hlds_pred, hlds__hlds_goal, parse_tree__prog_data.
-:- import_module backend_libs__code_model, ll_backend__code_util.
-:- import_module parse_tree__prog_util, check_hlds__type_util.
+:- import_module backend_libs__code_model.
+:- import_module backend_libs__rtti.
:- import_module check_hlds__mode_util.
-:- import_module hlds__quantification, transform_hlds__dependency_graph.
-:- import_module backend_libs__rtti, ll_backend__trace.
-:- import_module libs__options, libs__globals.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module hlds__quantification.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__trace.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_util.
+:- import_module transform_hlds__dependency_graph.
+
:- import_module bool, int, list, assoc_list, map, require, set.
:- import_module std_util, string, term, varset, counter.
Index: compiler/deforest.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/deforest.m,v
retrieving revision 1.28
diff -u -b -r1.28 deforest.m
--- compiler/deforest.m 28 Feb 2003 00:21:37 -0000 1.28
+++ compiler/deforest.m 14 Mar 2003 08:56:12 -0000
@@ -34,6 +34,7 @@
:- interface.
:- import_module hlds__hlds_module.
+
:- import_module io.
:- pred deforestation(module_info::in, module_info::out,
@@ -43,22 +44,36 @@
:- implementation.
-:- import_module transform_hlds__pd_cost, transform_hlds__pd_debug.
-:- import_module transform_hlds__pd_info, transform_hlds__pd_term.
-:- import_module transform_hlds__pd_util.
-:- import_module hlds__hlds_pred, hlds__hlds_goal, transform_hlds__inlining.
-:- import_module hlds__passes_aux.
-:- import_module (parse_tree__inst), hlds__instmap, check_hlds__inst_match.
-:- import_module check_hlds__simplify.
-:- import_module transform_hlds__dependency_graph, hlds__hlds_data.
-:- import_module check_hlds__det_analysis, libs__globals.
-:- import_module check_hlds__mode_util, hlds__goal_util.
-:- import_module parse_tree__prog_data, parse_tree__prog_util.
-:- import_module check_hlds__purity.
-:- import_module check_hlds__modes, check_hlds__mode_info.
-:- import_module check_hlds__unique_modes, libs__options, hlds__hlds_out.
-:- import_module parse_tree__prog_out, hlds__quantification.
+:- import_module check_hlds__det_analysis.
:- import_module check_hlds__det_report.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_info.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__modes.
+:- import_module check_hlds__purity.
+:- import_module check_hlds__simplify.
+:- import_module check_hlds__unique_modes.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_out.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module hlds__passes_aux.
+:- import_module hlds__quantification.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
+:- import_module transform_hlds__dependency_graph.
+:- import_module transform_hlds__inlining.
+:- import_module transform_hlds__pd_cost.
+:- import_module transform_hlds__pd_debug.
+:- import_module transform_hlds__pd_info.
+:- import_module transform_hlds__pd_term.
+:- import_module transform_hlds__pd_util.
:- import_module assoc_list, bool, getopt, int, list, map, require.
:- import_module set, std_util, string, term, varset.
Index: compiler/delay_construct.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/delay_construct.m,v
retrieving revision 1.3
diff -u -b -r1.3 delay_construct.m
--- compiler/delay_construct.m 28 Mar 2002 03:42:52 -0000 1.3
+++ compiler/delay_construct.m 14 Mar 2003 08:56:24 -0000
@@ -27,7 +27,8 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- import_module io.
:- pred delay_construct_proc(pred_id::in, proc_id::in, module_info::in,
@@ -37,9 +38,14 @@
:- implementation.
-:- import_module parse_tree__prog_data, hlds__hlds_data, hlds__hlds_goal.
-:- import_module hlds__passes_aux, libs__globals.
-:- import_module hlds__instmap, check_hlds__inst_match.
+:- import_module check_hlds__inst_match.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__instmap.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module parse_tree__prog_data.
+
:- import_module bool, list, set, std_util, require.
%-----------------------------------------------------------------------------%
Index: compiler/delay_info.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/delay_info.m,v
retrieving revision 1.18
diff -u -b -r1.18 delay_info.m
--- compiler/delay_info.m 20 Mar 2002 12:36:03 -0000 1.18
+++ compiler/delay_info.m 14 Mar 2003 08:56:55 -0000
@@ -20,8 +20,10 @@
:- interface.
-:- import_module hlds__hlds_goal, parse_tree__prog_data.
:- import_module check_hlds__mode_errors.
+:- import_module hlds__hlds_goal.
+:- import_module parse_tree__prog_data.
+
:- import_module list.
%-----------------------------------------------------------------------------%
@@ -90,9 +92,11 @@
%-----------------------------------------------------------------------------%
:- implementation.
+
+:- import_module check_hlds__mode_errors. % for the mode_error_info
+ % and delay_info types.
+
:- import_module int, stack, set, map, require, std_util.
-:- import_module check_hlds__mode_errors. % for the mode_error_info and delay_info
- % types.
% The delay_info structure is a tangled web of substructures
% all of which are pointing at each other - debugging it
Index: compiler/delay_slot.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/delay_slot.m,v
retrieving revision 1.8
diff -u -b -r1.8 delay_slot.m
--- compiler/delay_slot.m 20 Mar 2002 12:36:03 -0000 1.8
+++ compiler/delay_slot.m 14 Mar 2003 08:57:03 -0000
@@ -48,7 +48,9 @@
:- interface.
-:- import_module ll_backend__llds, list.
+:- import_module ll_backend__llds.
+
+:- import_module list.
% Delay the construction of det stack frames as long as possible,
% in order to avoid the construction in as many cases as possible.
Index: compiler/dense_switch.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/dense_switch.m,v
retrieving revision 1.43
diff -u -b -r1.43 dense_switch.m
--- compiler/dense_switch.m 9 Sep 2002 07:48:11 -0000 1.43
+++ compiler/dense_switch.m 14 Mar 2003 08:57:24 -0000
@@ -16,11 +16,14 @@
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_data, hlds__hlds_goal.
-:- import_module ll_backend__llds, ll_backend__code_info.
:- import_module backend_libs__code_model.
-:- import_module backend_libs__switch_util, check_hlds__type_util.
+:- import_module backend_libs__switch_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module ll_backend__code_info.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__prog_data.
% Should this switch be implemented as a dense jump table?
% If so, we return the starting and ending values for the table,
@@ -53,9 +56,12 @@
:- implementation.
-:- import_module hlds__hlds_goal, hlds__hlds_module, hlds__hlds_llds.
-:- import_module ll_backend__code_gen, ll_backend__trace.
:- import_module backend_libs__builtin_ops.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_llds.
+:- import_module hlds__hlds_module.
+:- import_module ll_backend__code_gen.
+:- import_module ll_backend__trace.
:- import_module char, map, libs__tree, int, std_util, require, list.
Index: compiler/dependency_graph.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/dependency_graph.m,v
retrieving revision 1.57
diff -u -b -r1.57 dependency_graph.m
--- compiler/dependency_graph.m 28 Mar 2002 03:42:52 -0000 1.57
+++ compiler/dependency_graph.m 14 Mar 2003 08:57:44 -0000
@@ -20,7 +20,9 @@
%-----------------------------------------------------------------------------%
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+
:- import_module bool, list, io.
% Ensure that the module_info contains a version of the
@@ -98,10 +100,15 @@
:- implementation.
-:- import_module hlds__hlds_goal, hlds__hlds_data, parse_tree__prog_data.
-:- import_module check_hlds__mode_util, libs__globals, libs__options.
-:- import_module ll_backend__code_util, hlds__goal_util.
+:- import_module check_hlds__mode_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ll_backend__code_util.
:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_data.
% XXX we should not import llds here -- this should depend only on the HLDS,
% not on the LLDS. But the LLDS stuff is unfortunately needed for producing
Index: compiler/det_analysis.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/det_analysis.m,v
retrieving revision 1.159
diff -u -b -r1.159 det_analysis.m
--- compiler/det_analysis.m 27 Jan 2003 09:20:45 -0000 1.159
+++ compiler/det_analysis.m 14 Mar 2003 08:58:04 -0000
@@ -52,10 +52,16 @@
:- interface.
+:- import_module check_hlds__det_report.
+:- import_module check_hlds__det_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module libs__globals.
:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_goal, hlds__hlds_module, hlds__hlds_pred.
-:- import_module hlds__hlds_data, hlds__instmap.
-:- import_module check_hlds__det_report, check_hlds__det_util, libs__globals.
+
:- import_module list, std_util, io.
% Perform determinism inference for local predicates with no
@@ -124,10 +130,15 @@
:- implementation.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__modecheck_call.
:- import_module check_hlds__purity.
-:- import_module check_hlds__type_util, check_hlds__modecheck_call.
-:- import_module check_hlds__mode_util, libs__options, hlds__passes_aux.
-:- import_module hlds__hlds_out, parse_tree__mercury_to_mercury.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_out.
+:- import_module hlds__passes_aux.
+:- import_module libs__options.
+:- import_module parse_tree__mercury_to_mercury.
+
:- import_module assoc_list, bool, map, set, require, term.
%-----------------------------------------------------------------------------%
Index: compiler/det_report.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/det_report.m,v
retrieving revision 1.77
diff -u -b -r1.77 det_report.m
--- compiler/det_report.m 28 Feb 2003 06:40:40 -0000 1.77
+++ compiler/det_report.m 14 Mar 2003 08:58:24 -0000
@@ -14,9 +14,11 @@
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_goal.
:- import_module check_hlds__det_util.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
:- import_module io, list.
@@ -135,12 +137,16 @@
:- implementation.
-:- import_module parse_tree__prog_out.
-:- import_module hlds__hlds_data, check_hlds__type_util.
-:- import_module check_hlds__mode_util, check_hlds__inst_match.
-:- import_module hlds__hlds_out, parse_tree__mercury_to_mercury.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_out.
:- import_module hlds__passes_aux.
-:- import_module libs__globals, libs__options.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_out.
:- import_module assoc_list, bool, int, map, set, std_util, require, string.
:- import_module getopt, term, varset.
Index: compiler/det_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/det_util.m,v
retrieving revision 1.24
diff -u -b -r1.24 det_util.m
--- compiler/det_util.m 27 Jan 2003 09:20:45 -0000 1.24
+++ compiler/det_util.m 14 Mar 2003 08:58:50 -0000
@@ -16,9 +16,14 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_goal.
-:- import_module hlds__hlds_data, libs__globals.
-:- import_module hlds__instmap, parse_tree__prog_data.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module libs__globals.
+:- import_module parse_tree__prog_data.
+
:- import_module bool, set, list.
:- type maybe_changed ---> changed ; unchanged.
@@ -97,9 +102,12 @@
:- implementation.
-:- import_module check_hlds__inst_match, check_hlds__mode_util.
-:- import_module check_hlds__type_util, libs__options, term.
-:- import_module map, require, std_util.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module libs__options.
+
+:- import_module map, term, require, std_util.
update_instmap(_Goal0 - GoalInfo0, InstMap0, InstMap) :-
goal_info_get_instmap_delta(GoalInfo0, DeltaInstMap),
Index: compiler/disj_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/disj_gen.m,v
retrieving revision 1.76
diff -u -b -r1.76 disj_gen.m
--- compiler/disj_gen.m 9 Sep 2002 07:48:11 -0000 1.76
+++ compiler/disj_gen.m 14 Mar 2003 08:59:09 -0000
@@ -17,8 +17,11 @@
:- interface.
-:- import_module hlds__hlds_goal, backend_libs__code_model, ll_backend__llds.
+:- import_module backend_libs__code_model.
+:- import_module hlds__hlds_goal.
:- import_module ll_backend__code_info.
+:- import_module ll_backend__llds.
+
:- import_module list.
:- pred disj_gen__generate_disj(code_model::in, list(hlds_goal)::in,
@@ -29,11 +32,15 @@
:- implementation.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_data, hlds__hlds_llds.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_llds.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__tree.
:- import_module ll_backend__code_gen.
-:- import_module ll_backend__code_util, ll_backend__trace.
-:- import_module libs__options, libs__globals, libs__tree.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__trace.
+:- import_module parse_tree__prog_data.
:- import_module bool, set, libs__tree, map, std_util, term, require.
Index: compiler/dnf.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/dnf.m,v
retrieving revision 1.47
diff -u -b -r1.47 dnf.m
--- compiler/dnf.m 28 Mar 2002 03:42:54 -0000 1.47
+++ compiler/dnf.m 14 Mar 2003 08:59:28 -0000
@@ -45,7 +45,9 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+
:- import_module set, list, bool, std_util.
:- pred dnf__transform_module(module_info::in, bool::in,
@@ -60,10 +62,16 @@
:- implementation.
-:- import_module ll_backend__code_aux, ll_backend__code_util, hlds__hlds_goal.
-:- import_module hlds__hlds_data, parse_tree__prog_data, hlds__instmap.
-:- import_module transform_hlds__dependency_graph, check_hlds__det_analysis.
+:- import_module check_hlds__det_analysis.
:- import_module check_hlds__mode_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__instmap.
+:- import_module ll_backend__code_aux.
+:- import_module ll_backend__code_util.
+:- import_module parse_tree__prog_data.
+:- import_module transform_hlds__dependency_graph.
+
:- import_module require, map, list, string, int, bool, std_util, term, varset.
% Traverse the module structure.
Index: compiler/dupelim.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/dupelim.m,v
retrieving revision 1.53
diff -u -b -r1.53 dupelim.m
--- compiler/dupelim.m 14 Mar 2003 08:10:05 -0000 1.53
+++ compiler/dupelim.m 14 Mar 2003 08:59:35 -0000
@@ -45,6 +45,7 @@
:- import_module backend_libs__proc_label.
:- import_module ll_backend__llds.
+
:- import_module list, counter.
:- pred dupelim_main(list(instruction)::in, proc_label::in,
Index: compiler/equiv_type.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/equiv_type.m,v
retrieving revision 1.31
diff -u -b -r1.31 equiv_type.m
--- compiler/equiv_type.m 27 Jan 2003 09:20:45 -0000 1.31
+++ compiler/equiv_type.m 14 Mar 2003 09:00:16 -0000
@@ -12,8 +12,11 @@
:- module parse_tree__equiv_type.
:- interface.
+
+:- import_module parse_tree__prog_data.
+:- import_module recompilation.
+
:- import_module bool, list, io, std_util.
-:- import_module recompilation, parse_tree__prog_data.
%-----------------------------------------------------------------------------%
@@ -53,13 +56,18 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module assoc_list, bool, require, std_util, map, set, term, varset.
-:- import_module parse_tree__prog_data, parse_tree__prog_util.
-:- import_module parse_tree__prog_out, parse_tree__inst.
% XXX we shouldn't import the HLDS here.
-:- import_module hlds__error_util, check_hlds__mode_util.
-:- import_module hlds__hlds_data, check_hlds__type_util.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module hlds__hlds_data.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
+
+:- import_module assoc_list, bool, require, std_util, map, set, term, varset.
%-----------------------------------------------------------------------------%
%-----------------------------------------------------------------------------%
Index: compiler/error_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/error_util.m,v
retrieving revision 1.20
diff -u -b -r1.20 error_util.m
--- compiler/error_util.m 17 Jan 2003 05:56:46 -0000 1.20
+++ compiler/error_util.m 14 Mar 2003 09:00:33 -0000
@@ -16,7 +16,10 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, parse_tree__prog_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
+
:- import_module assoc_list, char, io, list, std_util.
% Given a context, a starting indentation level and a list of words,
@@ -140,8 +143,11 @@
:- implementation.
-:- import_module parse_tree__prog_out, parse_tree__prog_util, libs__globals.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
+:- import_module libs__globals.
:- import_module libs__options.
+
:- import_module bool, io, list, term, char, string, int, require.
error_util__list_to_pieces([], []).
Index: compiler/exprn_aux.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/exprn_aux.m,v
retrieving revision 1.43
diff -u -b -r1.43 exprn_aux.m
--- compiler/exprn_aux.m 7 May 2002 11:02:43 -0000 1.43
+++ compiler/exprn_aux.m 14 Mar 2003 09:00:51 -0000
@@ -8,7 +8,10 @@
:- interface.
-:- import_module ll_backend__llds, libs__options, parse_tree__prog_data.
+:- import_module libs__options.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__prog_data.
+
:- import_module list, std_util, bool, assoc_list.
:- type exprn_opts
@@ -103,6 +106,7 @@
:- implementation.
:- import_module libs__options.
+
:- import_module int, set, require, getopt.
exprn_aux__init_exprn_opts(Options, ExprnOpts) :-
Index: compiler/fact_table.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/fact_table.m,v
retrieving revision 1.44
diff -u -b -r1.44 fact_table.m
--- compiler/fact_table.m 10 Jan 2003 10:36:27 -0000 1.44
+++ compiler/fact_table.m 14 Mar 2003 09:02:03 -0000
@@ -49,8 +49,11 @@
:- interface.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
+
:- import_module io, list.
-:- import_module parse_tree__prog_data, hlds__hlds_pred, hlds__hlds_module.
% compile the fact table into a separate .c file.
% fact_table_compile_facts(PredName, Arity, FileName, PredInfo0,
@@ -86,25 +89,34 @@
:- implementation.
-% Standard library modules
-:- import_module int, map, std_util, assoc_list, char, require, library, bool.
-:- import_module float, math, getopt, string.
-:- import_module parser, term, term_io.
-
% Parse tree modules
-:- import_module parse_tree__prog_util, parse_tree__prog_io.
-:- import_module parse_tree__prog_out, parse_tree__modules.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
% HLDS modules
-:- import_module hlds__hlds_out, hlds__hlds_data, check_hlds__mode_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_out.
+:- import_module hlds__passes_aux.
+:- import_module check_hlds__mode_util.
:- import_module check_hlds__inst_match.
% LLDS back-end modules
-:- import_module ll_backend__arg_info, ll_backend__llds, ll_backend__llds_out.
-:- import_module ll_backend__code_util, backend_libs__export.
-:- import_module backend_libs__foreign.
+:- import_module ll_backend__arg_info.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__llds.
+:- import_module ll_backend__llds_out.
% Modules shared between different back-ends.
-:- import_module hlds__passes_aux, backend_libs__code_model.
+:- import_module backend_libs__code_model.
+:- import_module backend_libs__export.
+:- import_module backend_libs__foreign.
% Misc
-:- import_module libs__globals, libs__options.
+:- import_module libs__globals.
+:- import_module libs__options.
+
+% Standard library modules
+:- import_module int, map, std_util, assoc_list, char, require, library, bool.
+:- import_module float, math, getopt, string.
+:- import_module parser, term, term_io.
:- type fact_result
---> ok ; error.
Index: compiler/follow_code.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/follow_code.m,v
retrieving revision 1.65
diff -u -b -r1.65 follow_code.m
--- compiler/follow_code.m 31 Oct 2002 05:47:49 -0000 1.65
+++ compiler/follow_code.m 14 Mar 2003 09:02:19 -0000
@@ -13,7 +13,10 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_goal.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+
:- import_module list.
:- pred move_follow_code_in_proc(pred_id::in, proc_id::in, pred_info::in,
@@ -29,10 +32,15 @@
:- implementation.
-:- import_module hlds__hlds_data, hlds__goal_util, check_hlds__mode_util.
-:- import_module parse_tree__prog_data.
-:- import_module libs__globals, libs__options, check_hlds__det_analysis.
+:- import_module check_hlds__det_analysis.
+:- import_module check_hlds__mode_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
:- import_module hlds__quantification.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__prog_data.
+
:- import_module bool, map, set, term, std_util, require.
%-----------------------------------------------------------------------------%
Index: compiler/follow_vars.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/follow_vars.m,v
retrieving revision 1.64
diff -u -b -r1.64 follow_vars.m
--- compiler/follow_vars.m 28 Mar 2002 03:42:55 -0000 1.64
+++ compiler/follow_vars.m 14 Mar 2003 09:02:34 -0000
@@ -28,9 +28,11 @@
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_goal.
+:- import_module hlds__hlds_goal.
:- import_module hlds__hlds_llds.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
:- import_module map.
@@ -46,12 +48,16 @@
:- implementation.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_data, hlds__quantification, check_hlds__mode_util.
:- import_module backend_libs__code_model.
-:- import_module ll_backend__llds, ll_backend__call_gen.
-:- import_module ll_backend__code_util, ll_backend__arg_info.
+:- import_module check_hlds__mode_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__quantification.
:- import_module libs__globals.
+:- import_module ll_backend__arg_info.
+:- import_module ll_backend__call_gen.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__prog_data.
:- import_module bool, int, list, assoc_list, map, set, std_util, require.
Index: compiler/foreign.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/foreign.m,v
retrieving revision 1.25
diff -u -b -r1.25 foreign.m
--- compiler/foreign.m 12 Feb 2003 22:58:07 -0000 1.25
+++ compiler/foreign.m 14 Mar 2003 09:03:08 -0000
@@ -18,8 +18,11 @@
:- interface.
-:- import_module parse_tree__prog_data, libs__globals.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_data.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module libs__globals.
+:- import_module parse_tree__prog_data.
:- import_module bool, list, string, term.
@@ -219,14 +222,19 @@
:- implementation.
+:- import_module backend_libs__code_model.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module libs__globals.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_out.
+
:- import_module list, map, assoc_list, std_util, string, varset, int, term.
:- import_module require.
-
-:- import_module hlds__hlds_pred, hlds__hlds_module, check_hlds__type_util.
-:- import_module check_hlds__mode_util, hlds__error_util.
-:- import_module hlds__hlds_data, parse_tree__prog_out.
-:- import_module backend_libs__code_model, libs__globals.
-:- import_module parse_tree__modules.
% Currently we don't use the globals to compare foreign language
% interfaces, but if we added appropriate options we might want
Index: compiler/frameopt.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/frameopt.m,v
retrieving revision 1.81
diff -u -b -r1.81 frameopt.m
--- compiler/frameopt.m 14 Mar 2003 08:10:06 -0000 1.81
+++ compiler/frameopt.m 14 Mar 2003 09:03:17 -0000
@@ -90,6 +90,7 @@
:- import_module backend_libs__proc_label.
:- import_module ll_backend__llds.
+
:- import_module bool, list, counter.
% The first bool output says whether we performed any modifications.
Index: compiler/gcc.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/gcc.m,v
retrieving revision 1.28
diff -u -b -r1.28 gcc.m
--- compiler/gcc.m 15 Sep 2002 18:52:19 -0000 1.28
+++ compiler/gcc.m 14 Mar 2003 09:03:37 -0000
@@ -64,6 +64,7 @@
:- module gcc.
:- interface.
+
:- import_module io, bool.
%-----------------------------------------------------------------------------%
@@ -672,6 +673,7 @@
%-----------------------------------------------------------------------------%
:- implementation.
+
:- import_module int, string.
:- pragma c_header_code("
Index: compiler/globals.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/globals.m,v
retrieving revision 1.53
diff -u -b -r1.53 globals.m
--- compiler/globals.m 11 Feb 2003 02:14:25 -0000 1.53
+++ compiler/globals.m 14 Mar 2003 09:04:00 -0000
@@ -16,8 +16,12 @@
%-----------------------------------------------------------------------------%
:- interface.
-:- import_module libs__options, libs__trace_params.
-:- import_module parse_tree, parse_tree__prog_data. % for module_name.
+
+:- import_module libs__options.
+:- import_module libs__trace_params.
+:- import_module parse_tree.
+:- import_module parse_tree__prog_data. % for module_name.
+
:- import_module bool, getopt, list, map, io, std_util.
:- type globals.
@@ -220,6 +224,7 @@
:- implementation.
:- import_module ll_backend__exprn_aux.
+
:- import_module map, std_util, require, string.
convert_target(String, Target) :-
Index: compiler/goal_form.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/goal_form.m,v
retrieving revision 1.3
diff -u -b -r1.3 goal_form.m
--- compiler/goal_form.m 18 Jul 2002 07:53:20 -0000 1.3
+++ compiler/goal_form.m 14 Mar 2003 09:04:10 -0000
@@ -16,7 +16,9 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_goal.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+
:- import_module list.
% Succeeds if the goal cannot loop forever.
@@ -60,6 +62,7 @@
:- import_module hlds__hlds_pred.
:- import_module transform_hlds__term_util.
+
:- import_module std_util.
%-----------------------------------------------------------------------------%
Index: compiler/goal_path.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/goal_path.m,v
retrieving revision 1.17
diff -u -b -r1.17 goal_path.m
--- compiler/goal_path.m 12 Aug 2002 09:39:51 -0000 1.17
+++ compiler/goal_path.m 14 Mar 2003 09:04:24 -0000
@@ -13,15 +13,19 @@
:- interface.
-:- import_module hlds__hlds_pred, hlds__hlds_module.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- pred goal_path__fill_slots(proc_info::in, module_info::in, proc_info::out)
is det.
:- implementation.
-:- import_module parse_tree__prog_data, hlds__hlds_data, hlds__hlds_goal.
:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module parse_tree__prog_data.
+
:- import_module char, int, list, map, std_util, require.
:- type slot_info
Index: compiler/goal_store.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/goal_store.m,v
retrieving revision 1.3
diff -u -b -r1.3 goal_store.m
--- compiler/goal_store.m 20 Mar 2002 12:36:12 -0000 1.3
+++ compiler/goal_store.m 14 Mar 2003 09:04:35 -0000
@@ -18,8 +18,11 @@
:- interface.
-:- import_module hlds__hlds_goal, hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- import_module hlds__instmap.
+
:- import_module bool, set, std_util.
%-----------------------------------------------------------------------------%
@@ -46,6 +49,7 @@
:- implementation.
:- import_module hlds__goal_util.
+
:- import_module int, list, map, require.
:- type goal_store(T) == map__map(T, goal).
Index: compiler/goal_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/goal_util.m,v
retrieving revision 1.82
diff -u -b -r1.82 goal_util.m
--- compiler/goal_util.m 28 Feb 2003 06:40:40 -0000 1.82
+++ compiler/goal_util.m 14 Mar 2003 09:04:56 -0000
@@ -14,9 +14,14 @@
:- module hlds__goal_util.
:- interface.
-:- import_module parse_tree__inst, parse_tree__prog_data.
-:- import_module hlds__hlds_data, hlds__hlds_goal, hlds__hlds_module.
-:- import_module hlds__hlds_pred, hlds__instmap.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+
:- import_module assoc_list, bool, list, set, map, term, std_util.
% The predicates rename_var* take a structure and a mapping from var -> var
@@ -239,11 +244,16 @@
:- implementation.
-:- import_module parse_tree__prog_data, parse_tree__inst.
-:- import_module hlds__hlds_data, hlds__goal_form, hlds__hlds_llds.
-:- import_module check_hlds__purity, check_hlds__det_analysis.
-:- import_module check_hlds__inst_match, check_hlds__mode_util.
+:- import_module check_hlds__det_analysis.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__purity.
:- import_module check_hlds__type_util.
+:- import_module hlds__goal_form.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_llds.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
:- import_module int, string, require, varset.
Index: compiler/handle_options.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/handle_options.m,v
retrieving revision 1.177
diff -u -b -r1.177 handle_options.m
--- compiler/handle_options.m 8 Mar 2003 05:41:30 -0000 1.177
+++ compiler/handle_options.m 14 Mar 2003 09:05:27 -0000
@@ -17,8 +17,11 @@
:- module libs__handle_options.
:- interface.
+
+:- import_module libs__globals.
+:- import_module libs__options.
+
:- import_module list, bool, getopt, std_util, io.
-:- import_module libs__globals, libs__options.
% handle_options(Args, MaybeError, OptionArgs, NonOptionArgs, Link).
:- pred handle_options(list(string), maybe(string), list(string),
@@ -69,9 +72,12 @@
:- implementation.
-:- import_module libs__options, libs__globals, parse_tree__prog_io_util.
-:- import_module libs__trace_params, check_hlds__unify_proc.
-:- import_module parse_tree__prog_data, backend_libs__foreign.
+:- import_module backend_libs__foreign.
+:- import_module check_hlds__unify_proc.
+:- import_module libs__trace_params.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_io_util.
+
:- import_module char, dir, int, string, map, set, library.
handle_options(Args0, MaybeError, OptionArgs, Args, Link) -->
Index: compiler/higher_order.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/higher_order.m,v
retrieving revision 1.103
diff -u -b -r1.103 higher_order.m
--- compiler/higher_order.m 28 Feb 2003 06:40:40 -0000 1.103
+++ compiler/higher_order.m 14 Mar 2003 09:05:52 -0000
@@ -26,6 +26,7 @@
:- interface.
:- import_module hlds__hlds_module.
+
:- import_module io.
:- pred specialize_higher_order(module_info::in, module_info::out,
@@ -35,15 +36,26 @@
:- implementation.
-:- import_module hlds__hlds_pred, hlds__hlds_goal, hlds__hlds_data.
-:- import_module hlds__instmap, (parse_tree__inst).
-:- import_module libs__globals, check_hlds__mode_util.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__polymorphism.
+:- import_module check_hlds__type_util.
+:- import_module check_hlds__unify_proc.
:- import_module hlds__goal_util.
-:- import_module check_hlds__type_util, libs__options, parse_tree__prog_data.
-:- import_module parse_tree__prog_out, hlds__quantification.
-:- import_module parse_tree__mercury_to_mercury, transform_hlds__inlining.
-:- import_module check_hlds__polymorphism, parse_tree__prog_util.
-:- import_module hlds__special_pred, check_hlds__unify_proc, hlds__passes_aux.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module hlds__passes_aux.
+:- import_module hlds__quantification.
+:- import_module hlds__special_pred.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
+:- import_module transform_hlds__inlining.
:- import_module assoc_list, bool, char, int, list, map, require, set.
:- import_module std_util, string, varset, term.
Index: compiler/hlds.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/hlds.m,v
retrieving revision 1.208
diff -u -b -r1.208 hlds.m
--- compiler/hlds.m 28 Mar 2002 03:42:59 -0000 1.208
+++ compiler/hlds.m 14 Mar 2003 09:07:36 -0000
@@ -10,33 +10,42 @@
:- module hlds.
:- interface.
-:- import_module parse_tree, libs.
+:- import_module backend_libs. % XXX needed for rtti, foreign, etc.
:- import_module check_hlds. % needed for unify_proc__unify_proc_id,
% etc.
-:- import_module transform_hlds. % needed for term_util, etc.
-:- import_module backend_libs. % XXX needed for rtti, foreign, etc.
+:- import_module libs.
% :- import_module ll_backend. % XXX needed for `llds__lval',
% which is used in various annotations
% in the HLDS (stack_slots, follow_vars, etc.)
+:- import_module parse_tree.
+:- import_module transform_hlds. % needed for term_util, etc.
%-----------------------------------------------------------------------------%
% The HLDS data structure itself
-:- include_module hlds_data, hlds_goal, hlds_pred, hlds_module.
-:- include_module hlds_llds, instmap.
-:- include_module (assertion), special_pred.
+:- include_module assertion.
+:- include_module hlds_data.
+:- include_module hlds_goal.
+:- include_module hlds_llds.
+:- include_module hlds_module.
+:- include_module hlds_pred.
+:- include_module instmap.
+:- include_module special_pred.
% Modules for creating the HLDS
-:- include_module make_hlds, make_tags.
+:- include_module make_hlds.
+:- include_module make_tags.
:- include_module quantification.
% Modules for pretty-printing it.
:- include_module hlds_out.
% Miscellaneous utilities.
-:- include_module passes_aux, error_util.
-:- include_module goal_form, goal_util.
+:- include_module error_util.
+:- include_module goal_form.
+:- include_module goal_util.
:- include_module hlds_code_util. % XXX currently code_util.m
+:- include_module passes_aux.
%-----------------------------------------------------------------------------%
Index: compiler/hlds_code_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/hlds_code_util.m,v
retrieving revision 1.2
diff -u -b -r1.2 hlds_code_util.m
--- compiler/hlds_code_util.m 10 Nov 2002 15:57:52 -0000 1.2
+++ compiler/hlds_code_util.m 14 Mar 2003 09:11:20 -0000
@@ -11,7 +11,9 @@
%
%-----------------------------------------------------------------------------%
%-----------------------------------------------------------------------------%
+
:- module hlds__hlds_code_util.
+
:- interface.
:- import_module hlds__hlds_module.
@@ -25,7 +27,9 @@
:- implementation.
-:- import_module libs__globals, libs__options.
+:- import_module libs__globals.
+:- import_module libs__options.
+
:- import_module bool.
are_equivalence_types_expanded(ModuleInfo) :-
@@ -34,5 +38,3 @@
HighLevelData = yes,
globals__get_target(Globals, Target),
( Target = il ; Target = java).
-
-
Index: compiler/hlds_data.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/hlds_data.m,v
retrieving revision 1.74
diff -u -b -r1.74 hlds_data.m
--- compiler/hlds_data.m 12 Feb 2003 22:58:07 -0000 1.74
+++ compiler/hlds_data.m 14 Mar 2003 09:11:44 -0000
@@ -13,8 +13,11 @@
:- interface.
-:- import_module hlds__hlds_pred, parse_tree__prog_data, (parse_tree__inst).
:- import_module backend_libs__rtti.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+
:- import_module bool, list, map, std_util, term.
%-----------------------------------------------------------------------------%
@@ -166,8 +169,9 @@
:- implementation.
-:- import_module parse_tree__prog_util, varset.
-:- import_module require.
+:- import_module parse_tree__prog_util.
+
+:- import_module require, varset.
cons_id_and_args_to_term(int_const(Int), [], Term) :-
term__context_init(Context),
Index: compiler/hlds_goal.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/hlds_goal.m,v
retrieving revision 1.102
diff -u -b -r1.102 hlds_goal.m
--- compiler/hlds_goal.m 28 Feb 2003 00:21:37 -0000 1.102
+++ compiler/hlds_goal.m 14 Mar 2003 09:12:13 -0000
@@ -12,9 +12,12 @@
:- interface.
-:- import_module parse_tree__prog_data, parse_tree__inst.
-:- import_module hlds__hlds_data, hlds__hlds_pred, hlds__hlds_llds.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_llds.
+:- import_module hlds__hlds_pred.
:- import_module hlds__instmap.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
:- import_module bool, char, list, set, map, std_util.
@@ -1128,9 +1131,11 @@
:- implementation.
+:- import_module check_hlds__det_analysis.
:- import_module check_hlds__purity.
-:- import_module check_hlds__det_analysis, parse_tree__prog_util.
:- import_module check_hlds__type_util.
+:- import_module parse_tree__prog_util.
+
:- import_module require, string, term, varset.
%-----------------------------------------------------------------------------%
@@ -1153,6 +1158,7 @@
simple_call_id_pred_or_func(CallId).
:- func simple_call_id_pred_or_func(simple_call_id) = pred_or_func.
+
simple_call_id_pred_or_func(PredOrFunc - _) = PredOrFunc.
%-----------------------------------------------------------------------------%
Index: compiler/hlds_llds.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/hlds_llds.m,v
retrieving revision 1.1
diff -u -b -r1.1 hlds_llds.m
--- compiler/hlds_llds.m 28 Mar 2002 03:43:01 -0000 1.1
+++ compiler/hlds_llds.m 14 Mar 2003 09:12:27 -0000
@@ -13,7 +13,10 @@
:- interface.
-:- import_module hlds__hlds_goal, parse_tree__prog_data, ll_backend__llds.
+:- import_module hlds__hlds_goal.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__prog_data.
+
:- import_module bool, map, set, std_util.
%
@@ -251,6 +254,7 @@
:- implementation.
:- import_module hlds__goal_util.
+
:- import_module list, assoc_list, require.
% For the meaning of this type, see the documentation of the
Index: compiler/hlds_module.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/hlds_module.m,v
retrieving revision 1.81
diff -u -b -r1.81 hlds_module.m
--- compiler/hlds_module.m 10 Mar 2003 14:10:53 -0000 1.81
+++ compiler/hlds_module.m 14 Mar 2003 09:13:00 -0000
@@ -21,18 +21,26 @@
:- interface.
-:- import_module parse_tree__prog_data, parse_tree__module_qual.
-:- import_module recompilation.
-:- import_module hlds__hlds_pred, hlds__hlds_data, check_hlds__unify_proc.
-:- import_module hlds__special_pred.
-:- import_module libs__globals, backend_libs__foreign.
:- import_module analysis.
+:- import_module backend_libs__foreign.
+:- import_module check_hlds__unify_proc.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__special_pred.
+:- import_module libs__globals.
+:- import_module parse_tree__module_qual.
+:- import_module parse_tree__prog_data.
+:- import_module recompilation.
+
:- import_module relation, map, std_util, list, set, multi_map, counter.
:- implementation.
-:- import_module hlds__hlds_out, parse_tree__prog_out, parse_tree__prog_util.
-:- import_module check_hlds__typecheck, parse_tree__modules.
+:- import_module check_hlds__typecheck.
+:- import_module hlds__hlds_out.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
:- import_module transform_hlds__mmc_analysis.
:- import_module bool, require, int, string.
Index: compiler/hlds_out.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/hlds_out.m,v
retrieving revision 1.298
diff -u -b -r1.298 hlds_out.m
--- compiler/hlds_out.m 10 Mar 2003 14:10:53 -0000 1.298
+++ compiler/hlds_out.m 14 Mar 2003 09:13:44 -0000
@@ -33,10 +33,14 @@
:- interface.
% Parse tree modules
-:- import_module parse_tree__prog_data, (parse_tree__inst).
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
% HLDS modules
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_goal.
-:- import_module hlds__hlds_data, hlds__instmap.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
:- import_module io, bool, list, term.
@@ -257,26 +261,36 @@
:- implementation.
% Parse tree modules.
-:- import_module parse_tree__prog_out, parse_tree__prog_util.
-:- import_module parse_tree__inst, parse_tree__mercury_to_mercury.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
% HLDS modules.
-:- import_module hlds__special_pred, hlds__instmap, hlds__hlds_llds.
-:- import_module check_hlds__purity, check_hlds__check_typeclass.
+:- import_module check_hlds__check_typeclass.
+:- import_module check_hlds__purity.
:- import_module check_hlds__type_util.
-:- import_module transform_hlds__termination, transform_hlds__term_errors.
+:- import_module hlds__hlds_llds.
+:- import_module hlds__instmap.
+:- import_module hlds__special_pred.
+:- import_module transform_hlds__term_errors.
+:- import_module transform_hlds__termination.
% RL back-end modules (XXX should avoid using those here).
:- import_module aditi_backend__rl.
% LLDS back-end modules (XXX should avoid using those here).
:- import_module ll_backend.
-:- import_module ll_backend__code_util, ll_backend__llds.
-:- import_module ll_backend__llds_out, ll_backend__trace.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__llds.
+:- import_module ll_backend__llds_out.
+:- import_module ll_backend__trace.
% Misc
-:- import_module backend_libs__rtti, backend_libs__foreign.
-:- import_module libs__globals, libs__options.
+:- import_module backend_libs__foreign.
+:- import_module backend_libs__rtti.
+:- import_module libs__globals.
+:- import_module libs__options.
% Standard library modules
:- import_module int, string, set, assoc_list, map, multi_map.
Index: compiler/hlds_pred.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/hlds_pred.m,v
retrieving revision 1.119
diff -u -b -r1.119 hlds_pred.m
--- compiler/hlds_pred.m 10 Mar 2003 14:10:54 -0000 1.119
+++ compiler/hlds_pred.m 14 Mar 2003 09:14:04 -0000
@@ -13,12 +13,15 @@
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_data, hlds__hlds_goal, hlds__hlds_module.
-:- import_module hlds__instmap, hlds__hlds_llds.
:- import_module check_hlds__mode_errors.
-:- import_module transform_hlds__term_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_llds.
+:- import_module hlds__hlds_module.
+:- import_module hlds__instmap.
:- import_module libs__globals.
+:- import_module parse_tree__prog_data.
+:- import_module transform_hlds__term_util.
:- import_module bool, list, set, map, std_util, term, varset.
@@ -28,9 +31,12 @@
:- import_module parse_tree__prog_util.
% HLDS modules.
-:- import_module hlds__goal_util, hlds__make_hlds, hlds__goal_form.
-:- import_module check_hlds__inst_match, check_hlds__mode_util.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
:- import_module check_hlds__type_util.
+:- import_module hlds__goal_form.
+:- import_module hlds__goal_util.
+:- import_module hlds__make_hlds.
% Misc
:- import_module libs__options.
Index: compiler/il_peephole.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/il_peephole.m,v
retrieving revision 1.7
diff -u -b -r1.7 il_peephole.m
--- compiler/il_peephole.m 20 Mar 2002 12:36:22 -0000 1.7
+++ compiler/il_peephole.m 14 Mar 2003 09:14:20 -0000
@@ -34,9 +34,10 @@
:- interface.
-:- import_module list.
:- import_module ml_backend__ilasm.
+:- import_module list.
+
% Peephole optimize a list of instructions.
:- pred il_peephole__optimize(list(ilasm__decl)::in, list(ilasm__decl)::out)
@@ -46,8 +47,9 @@
:- type instrs == list(instr).
-:- import_module assoc_list, bool, map, string, std_util, int.
-:- import_module ml_backend__ilds, require.
+:- import_module ml_backend__ilds.
+
+:- import_module assoc_list, bool, map, string, std_util, int, require.
% We zip down to the end of the instruction list, and start attempting
% to optimize instruction sequences. As long as we can continue
Index: compiler/ilasm.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ilasm.m,v
retrieving revision 1.35
diff -u -b -r1.35 ilasm.m
--- compiler/ilasm.m 24 Nov 2002 03:57:22 -0000 1.35
+++ compiler/ilasm.m 14 Mar 2003 09:14:47 -0000
@@ -24,9 +24,10 @@
:- interface.
-:- import_module io, list, term, std_util, bool, integer.
:- import_module ml_backend__ilds.
+:- import_module io, list, term, std_util, bool, integer.
+
:- pred ilasm__output(
list(decl)::in, io__state::di, io__state::uo) is det.
@@ -271,11 +272,13 @@
:- implementation.
-:- import_module char, string, pprint, getopt.
-:- import_module require, int, term_io, varset, bool.
-:- import_module libs__globals, libs__options, hlds__error_util.
:- import_module backend_libs__c_util. % for output_float_literal
+:- import_module hlds__error_util.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module char, string, pprint, getopt.
+:- import_module require, int, term_io, varset, bool.
% Some versions of the IL assembler enforce a rule that if you output
% .assembly foo { }
Index: compiler/ilds.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ilds.m,v
retrieving revision 1.15
diff -u -b -r1.15 ilds.m
--- compiler/ilds.m 20 Mar 2002 12:36:23 -0000 1.15
+++ compiler/ilds.m 14 Mar 2003 09:15:03 -0000
@@ -386,8 +386,9 @@
:- implementation.
-:- import_module int, require.
:- import_module hlds__error_util.
+
+:- import_module int, require.
get_class_suffix(structured_name(_, OuterClassFullName, NestedClass))
= SuffixName :-
Index: compiler/inlining.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/inlining.m,v
retrieving revision 1.109
diff -u -b -r1.109 inlining.m
--- compiler/inlining.m 30 Jul 2002 08:25:01 -0000 1.109
+++ compiler/inlining.m 14 Mar 2003 09:15:31 -0000
@@ -83,8 +83,11 @@
:- interface.
-:- import_module hlds__hlds_goal, hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- import_module parse_tree__prog_data.
+
:- import_module bool, io, list, map.
:- pred inlining(module_info, module_info, io__state, io__state).
@@ -151,16 +154,22 @@
:- import_module parse_tree__prog_data.
% HLDS modules
-:- import_module hlds__hlds_data, check_hlds__type_util.
-:- import_module check_hlds__mode_util, hlds__goal_util.
:- import_module check_hlds__det_analysis.
-:- import_module hlds__quantification, ll_backend__code_aux.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__purity.
+:- import_module check_hlds__type_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__passes_aux.
+:- import_module hlds__quantification.
+:- import_module ll_backend__code_aux.
:- import_module transform_hlds__dead_proc_elim.
:- import_module transform_hlds__dependency_graph.
-:- import_module hlds__passes_aux, check_hlds__purity.
% Misc
-:- import_module libs__globals, libs__options, libs__trace_params.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__trace_params.
% Standard library modules
:- import_module bool, int, list, assoc_list, set, std_util, require.
Index: compiler/inst.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/inst.m,v
retrieving revision 1.9
diff -u -b -r1.9 inst.m
--- compiler/inst.m 20 Mar 2002 12:36:23 -0000 1.9
+++ compiler/inst.m 14 Mar 2003 09:15:39 -0000
@@ -22,7 +22,9 @@
% of the `cons_id' type, and so we could define a new type
% `abstract_cons_id' and use that here instead of `cons_id'.
-:- import_module parse_tree__prog_data, hlds__hlds_data.
+:- import_module hlds__hlds_data.
+:- import_module parse_tree__prog_data.
+
:- import_module list, map, set.
%-----------------------------------------------------------------------------%
Index: compiler/inst_match.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/inst_match.m,v
retrieving revision 1.51
diff -u -b -r1.51 inst_match.m
--- compiler/inst_match.m 10 Jan 2003 10:45:00 -0000 1.51
+++ compiler/inst_match.m 14 Mar 2003 09:16:03 -0000
@@ -39,7 +39,10 @@
:- interface.
-:- import_module hlds__hlds_module, parse_tree__prog_data, (parse_tree__inst).
+:- import_module hlds__hlds_module.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+
:- import_module list.
%-----------------------------------------------------------------------------%
@@ -285,9 +288,13 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module hlds__hlds_data, check_hlds__mode_util.
-:- import_module parse_tree__prog_data, check_hlds__inst_util.
+
+:- import_module check_hlds__inst_util.
+:- import_module check_hlds__mode_util.
:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+:- import_module parse_tree__prog_data.
+
:- import_module list, set, map, term, std_util, require, bool.
inst_matches_initial(InstA, InstB, Type, ModuleInfo) :-
Index: compiler/inst_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/inst_util.m,v
retrieving revision 1.24
diff -u -b -r1.24 inst_util.m
--- compiler/inst_util.m 12 Aug 2002 07:34:57 -0000 1.24
+++ compiler/inst_util.m 14 Mar 2003 09:16:25 -0000
@@ -41,8 +41,11 @@
:- module check_hlds__inst_util.
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_data, parse_tree__prog_data.
-:- import_module (parse_tree__inst).
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+
:- import_module list, std_util.
:- pred abstractly_unify_inst(is_live, inst, inst, unify_is_real, module_info,
@@ -130,9 +133,13 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module hlds__hlds_data, check_hlds__inst_match.
-:- import_module check_hlds__mode_util, check_hlds__det_analysis.
+
+:- import_module check_hlds__det_analysis.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+
:- import_module bool, std_util, require, map, list, set, int.
% Abstractly unify two insts.
Index: compiler/instmap.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/instmap.m,v
retrieving revision 1.29
diff -u -b -r1.29 instmap.m
--- compiler/instmap.m 20 Mar 2002 12:36:26 -0000 1.29
+++ compiler/instmap.m 14 Mar 2003 09:16:48 -0000
@@ -19,10 +19,13 @@
:- interface.
-:- import_module hlds__hlds_module, parse_tree__prog_data.
-:- import_module check_hlds__mode_info, (parse_tree__inst).
:- import_module check_hlds__mode_errors.
-:- import_module hlds__hlds_data, hlds__hlds_pred.
+:- import_module check_hlds__mode_info.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
:- import_module map, bool, set, list, assoc_list, std_util.
@@ -308,9 +311,13 @@
:- implementation.
-:- import_module check_hlds__mode_util, check_hlds__inst_match.
-:- import_module parse_tree__prog_data, hlds__goal_util, check_hlds__type_util.
-:- import_module hlds__hlds_data, check_hlds__inst_util.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__inst_util.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module parse_tree__prog_data.
:- import_module std_util, require, string, term.
Index: compiler/intermod.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/intermod.m,v
retrieving revision 1.134
diff -u -b -r1.134 intermod.m
--- compiler/intermod.m 10 Mar 2003 14:10:54 -0000 1.134
+++ compiler/intermod.m 14 Mar 2003 09:17:19 -0000
@@ -39,9 +39,12 @@
:- interface.
-:- import_module io, bool.
-:- import_module hlds__hlds_module, parse_tree__modules, parse_tree__prog_io.
+:- import_module hlds__hlds_module.
+:- import_module parse_tree__modules.
:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_io.
+
+:- import_module io, bool.
:- pred intermod__write_optfile(module_info, module_info,
io__state, io__state).
@@ -86,20 +89,32 @@
:- implementation.
-:- import_module assoc_list, dir, getopt, int, list, map, multi_map, require.
-:- import_module set, std_util, string, term, varset.
-
-:- import_module libs__globals, hlds__goal_util.
-:- import_module hlds__hlds_data, hlds__hlds_goal, hlds__hlds_pred.
-:- import_module hlds__hlds_out, transform_hlds__inlining, ll_backend__llds.
-:- import_module parse_tree__mercury_to_mercury, check_hlds__mode_util.
+:- import_module backend_libs__foreign.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module check_hlds__typecheck.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_out.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module hlds__passes_aux.
+:- import_module hlds__special_pred.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__mercury_to_mercury.
:- import_module parse_tree__modules.
-:- import_module libs__options, hlds__passes_aux, parse_tree__prog_data.
-:- import_module parse_tree__prog_io, parse_tree__prog_out.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_out.
:- import_module parse_tree__prog_util.
-:- import_module hlds__special_pred, check_hlds__typecheck.
-:- import_module check_hlds__type_util, hlds__instmap, (parse_tree__inst).
-:- import_module backend_libs__foreign.
+:- import_module transform_hlds__inlining.
+
+:- import_module assoc_list, dir, getopt, int, list, map, multi_map, require.
+:- import_module set, std_util, string, term, varset.
%-----------------------------------------------------------------------------%
Index: compiler/ite_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ite_gen.m,v
retrieving revision 1.68
diff -u -b -r1.68 ite_gen.m
--- compiler/ite_gen.m 9 Sep 2002 07:48:13 -0000 1.68
+++ compiler/ite_gen.m 14 Mar 2003 09:17:34 -0000
@@ -18,8 +18,10 @@
:- interface.
-:- import_module hlds__hlds_goal, backend_libs__code_model, ll_backend__llds.
+:- import_module backend_libs__code_model.
+:- import_module hlds__hlds_goal.
:- import_module ll_backend__code_info.
+:- import_module ll_backend__llds.
:- pred ite_gen__generate_ite(code_model::in, hlds_goal::in, hlds_goal::in,
hlds_goal::in, hlds_goal_info::in, code_tree::out,
@@ -33,12 +35,16 @@
:- implementation.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__instmap, hlds__hlds_llds.
-:- import_module ll_backend__code_gen, ll_backend__code_util.
-:- import_module ll_backend__trace.
:- import_module backend_libs__builtin_ops.
-:- import_module libs__options, libs__globals, libs__tree.
+:- import_module hlds__hlds_llds.
+:- import_module hlds__instmap.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__tree.
+:- import_module ll_backend__code_gen.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__trace.
+:- import_module parse_tree__prog_data.
:- import_module bool, set, term, list, map, std_util, require.
Index: compiler/java_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/java_util.m,v
retrieving revision 1.7
diff -u -b -r1.7 java_util.m
--- compiler/java_util.m 10 Jan 2003 10:45:00 -0000 1.7
+++ compiler/java_util.m 14 Mar 2003 09:17:44 -0000
@@ -15,9 +15,11 @@
:- module ml_backend__java_util.
:- interface.
-:- import_module string.
+
:- import_module backend_libs__builtin_ops.
+:- import_module string.
+
%-----------------------------------------------------------------------------%
% Succeeds iff the given string matches a reserved
@@ -71,8 +73,10 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module list.
+
:- import_module hlds__error_util.
+
+:- import_module list.
%-----------------------------------------------------------------------------%
Index: compiler/jumpopt.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/jumpopt.m,v
retrieving revision 1.63
diff -u -b -r1.63 jumpopt.m
--- compiler/jumpopt.m 14 Mar 2003 08:10:06 -0000 1.63
+++ compiler/jumpopt.m 14 Mar 2003 09:17:51 -0000
@@ -16,6 +16,7 @@
:- import_module backend_libs__proc_label.
:- import_module ll_backend__llds.
+
:- import_module list, set, bool, counter.
% Take an instruction list and optimize jumps. This includes jumps
Index: compiler/labelopt.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/labelopt.m,v
retrieving revision 1.21
diff -u -b -r1.21 labelopt.m
--- compiler/labelopt.m 20 Mar 2002 12:36:28 -0000 1.21
+++ compiler/labelopt.m 14 Mar 2003 09:17:58 -0000
@@ -14,9 +14,10 @@
:- interface.
-:- import_module bool, list, set.
:- import_module ll_backend__llds.
+:- import_module bool, list, set.
+
% Build up a set showing which labels are branched to,
% then traverse the instruction list removing unnecessary labels.
% If the instruction before the label branches away, we also
@@ -37,6 +38,7 @@
:- implementation.
:- import_module ll_backend__opt_util.
+
:- import_module std_util.
labelopt_main(Instrs0, Final, LayoutLabelSet, Instrs, Mod) :-
Index: compiler/lambda.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/lambda.m,v
retrieving revision 1.79
diff -u -b -r1.79 lambda.m
--- compiler/lambda.m 27 Jan 2003 09:20:46 -0000 1.79
+++ compiler/lambda.m 14 Mar 2003 09:18:31 -0000
@@ -69,7 +69,8 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- pred lambda__process_module(module_info, module_info).
:- mode lambda__process_module(in, out) is det.
@@ -82,16 +83,25 @@
:- implementation.
-:- import_module backend_libs__code_model. % XXX for some back-end dependent optimizations
+:- import_module backend_libs__code_model. % XXX for some back-end dependent
+ % optimizations
% Parse tree modules
-:- import_module parse_tree__prog_data, parse_tree__prog_util.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_util.
+
% HLDS modules
-:- import_module hlds__hlds_goal, hlds__hlds_data, hlds__quantification.
-:- import_module check_hlds__type_util, hlds__goal_util.
-:- import_module check_hlds__mode_util, check_hlds__inst_match.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__quantification.
+
% Misc
-:- import_module libs__globals, libs__options.
+:- import_module libs__globals.
+:- import_module libs__options.
% Standard library modules
:- import_module list, map, set.
Index: compiler/lco.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/lco.m,v
retrieving revision 1.19
diff -u -b -r1.19 lco.m
--- compiler/lco.m 28 Mar 2002 03:43:08 -0000 1.19
+++ compiler/lco.m 14 Mar 2003 09:18:50 -0000
@@ -15,7 +15,9 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+
:- import_module io.
:- pred lco_modulo_constructors(pred_id, proc_id, module_info,
@@ -27,7 +29,10 @@
:- implementation.
-:- import_module hlds__hlds_goal, hlds__passes_aux, hlds__hlds_out.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_out.
+:- import_module hlds__passes_aux.
+
:- import_module list, require, std_util.
%-----------------------------------------------------------------------------%
Index: compiler/libs.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/libs.m,v
retrieving revision 1.1
diff -u -b -r1.1 libs.m
--- compiler/libs.m 20 Mar 2002 12:36:29 -0000 1.1
+++ compiler/libs.m 14 Mar 2003 09:19:21 -0000
@@ -9,18 +9,24 @@
:- module libs.
:- interface.
+
:- import_module ll_backend. % XXX trace_params depends on llds__trace_port.
% option handling
-:- include_module globals, options, handle_options, trace_params.
+:- include_module globals.
+:- include_module handle_options.
+:- include_module options.
+:- include_module trace_params.
% generic algorithms and data structures that are not
% quite useful enough to go in the standard library
-:- include_module tree, graph_colour, atsort.
+:- include_module atsort.
+:- include_module graph_colour.
+:- include_module tree.
% OS interfaces not provided by the standard library
-:- include_module timestamp.
:- include_module process_util.
+:- include_module timestamp.
:- end_module libs.
Index: compiler/live_vars.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/live_vars.m,v
retrieving revision 1.100
diff -u -b -r1.100 live_vars.m
--- compiler/live_vars.m 28 Mar 2002 03:43:08 -0000 1.100
+++ compiler/live_vars.m 14 Mar 2003 09:19:39 -0000
@@ -26,8 +26,10 @@
:- import_module parse_tree__prog_data.
% HLDS modules
-:- import_module hlds__hlds_goal, hlds__hlds_pred, hlds__hlds_module.
+:- import_module hlds__hlds_goal.
:- import_module hlds__hlds_llds.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
% Standard library modules
:- import_module bool, set.
@@ -60,12 +62,16 @@
:- implementation.
-:- import_module hlds__hlds_goal, hlds__hlds_llds, hlds__hlds_data.
-:- import_module hlds__instmap.
-:- import_module check_hlds__mode_util.
-:- import_module ll_backend__llds, ll_backend__arg_info.
-:- import_module ll_backend__liveness, ll_backend__code_aux.
:- import_module backend_libs__code_model.
+:- import_module check_hlds__mode_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_llds.
+:- import_module hlds__instmap.
+:- import_module ll_backend__arg_info.
+:- import_module ll_backend__code_aux.
+:- import_module ll_backend__liveness.
+:- import_module ll_backend__llds.
:- import_module int, list, assoc_list, map, std_util, require.
Index: compiler/livemap.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/livemap.m,v
retrieving revision 1.53
diff -u -b -r1.53 livemap.m
--- compiler/livemap.m 7 May 2002 11:02:49 -0000 1.53
+++ compiler/livemap.m 14 Mar 2003 09:19:46 -0000
@@ -16,9 +16,10 @@
:- interface.
-:- import_module list, set, map, std_util.
:- import_module ll_backend__llds.
+:- import_module list, set, map, std_util.
+
:- type livemap == map(label, lvalset).
:- type lvalset == set(lval).
@@ -32,6 +33,7 @@
:- implementation.
:- import_module ll_backend__opt_util.
+
:- import_module require, string, bool.
%-----------------------------------------------------------------------------%
Index: compiler/liveness.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/liveness.m,v
retrieving revision 1.122
diff -u -b -r1.122 liveness.m
--- compiler/liveness.m 31 Oct 2002 05:47:50 -0000 1.122
+++ compiler/liveness.m 14 Mar 2003 09:20:23 -0000
@@ -155,7 +155,10 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, parse_tree__prog_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
+
:- import_module set, io.
% Add liveness annotations to the goal of the procedure.
@@ -176,23 +179,33 @@
:- implementation.
% Parse tree modules
-:- import_module parse_tree__prog_util, parse_tree__inst.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_util.
% HLDS modules
-:- import_module hlds__hlds_goal, hlds__hlds_llds.
-:- import_module hlds__hlds_data, hlds__hlds_out.
-:- import_module hlds__instmap, hlds__quantification, hlds__passes_aux.
-:- import_module check_hlds__mode_util, check_hlds__polymorphism.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__polymorphism.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_llds.
+:- import_module hlds__hlds_out.
+:- import_module hlds__instmap.
+:- import_module hlds__passes_aux.
+:- import_module hlds__quantification.
% LLDS modules
-:- import_module ll_backend__llds, ll_backend__code_util.
-:- import_module ll_backend__arg_info, ll_backend__trace.
+:- import_module ll_backend__arg_info.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__llds.
+:- import_module ll_backend__trace.
% Modules shared between different back-ends.
:- import_module backend_libs__code_model.
% Misc
-:- import_module libs__trace_params, libs__globals, libs__options.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__trace_params.
% Standard library modules
:- import_module bool, string, map, std_util, list, assoc_list, require.
Index: compiler/ll_pseudo_type_info.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ll_pseudo_type_info.m,v
retrieving revision 1.6
diff -u -b -r1.6 ll_pseudo_type_info.m
--- compiler/ll_pseudo_type_info.m 8 Aug 2002 08:15:40 -0000 1.6
+++ compiler/ll_pseudo_type_info.m 14 Mar 2003 09:20:46 -0000
@@ -23,7 +23,9 @@
:- interface.
-:- import_module parse_tree__prog_data, ll_backend__llds.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__prog_data.
+
:- import_module counter.
% ll_pseudo_type_info__construct_typed_pseudo_type_info(Type,
@@ -57,7 +59,10 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module backend_libs__pseudo_type_info, backend_libs__rtti.
+
+:- import_module backend_libs__pseudo_type_info.
+:- import_module backend_libs__rtti.
+
:- import_module std_util, list, bool, int.
ll_pseudo_type_info__construct_llds_pseudo_type_info(Type, NumUnivQTvars,
Index: compiler/llds_common.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/llds_common.m,v
retrieving revision 1.46
diff -u -b -r1.46 llds_common.m
--- compiler/llds_common.m 15 Nov 2002 04:50:23 -0000 1.46
+++ compiler/llds_common.m 14 Mar 2003 09:21:07 -0000
@@ -22,6 +22,7 @@
:- import_module ll_backend__llds.
:- import_module parse_tree__prog_data. % for module_name
+
:- import_module list.
:- pred llds_common(list(c_procedure)::in, list(comp_gen_c_data)::in,
@@ -30,7 +31,10 @@
:- implementation.
-:- import_module backend_libs__rtti, ll_backend__layout, ll_backend__llds_out.
+:- import_module backend_libs__rtti.
+:- import_module ll_backend__layout.
+:- import_module ll_backend__llds_out.
+
:- import_module bool, int, assoc_list, map, std_util, require.
:- type cell_info
Index: compiler/llds_out.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/llds_out.m,v
retrieving revision 1.205
diff -u -b -r1.205 llds_out.m
--- compiler/llds_out.m 14 Mar 2003 08:10:06 -0000 1.205
+++ compiler/llds_out.m 14 Mar 2003 09:21:28 -0000
@@ -273,16 +273,23 @@
:- implementation.
-:- import_module parse_tree__modules, parse_tree__prog_out.
-:- import_module parse_tree__mercury_to_mercury.
-:- import_module hlds__hlds_pred, hlds__passes_aux.
-:- import_module ll_backend__layout, ll_backend__layout_out.
-:- import_module ll_backend__rtti_out.
-:- import_module ll_backend__exprn_aux, parse_tree__prog_util.
-:- import_module backend_libs__rtti, backend_libs__export.
-:- import_module backend_libs__c_util, backend_libs__foreign.
+:- import_module backend_libs__c_util.
:- import_module backend_libs__compile_target_code.
-:- import_module libs__options, libs__trace_params.
+:- import_module backend_libs__export.
+:- import_module backend_libs__foreign.
+:- import_module backend_libs__rtti.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__passes_aux.
+:- import_module libs__options.
+:- import_module libs__trace_params.
+:- import_module ll_backend__exprn_aux.
+:- import_module ll_backend__layout.
+:- import_module ll_backend__layout_out.
+:- import_module ll_backend__rtti_out.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
:- import_module int, char, string, std_util.
:- import_module set, bintree_set, assoc_list, require.
Index: compiler/lookup_switch.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/lookup_switch.m,v
retrieving revision 1.44
diff -u -b -r1.44 lookup_switch.m
--- compiler/lookup_switch.m 28 Mar 2002 03:43:11 -0000 1.44
+++ compiler/lookup_switch.m 14 Mar 2003 09:21:45 -0000
@@ -41,10 +41,14 @@
:- interface.
+:- import_module backend_libs__code_model.
+:- import_module backend_libs__switch_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_llds.
+:- import_module ll_backend__code_info.
+:- import_module ll_backend__llds.
:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_goal, hlds__hlds_data, hlds__hlds_llds.
-:- import_module ll_backend__llds, ll_backend__code_info.
-:- import_module backend_libs__switch_util, backend_libs__code_model.
:- import_module std_util, map, set, list.
@@ -69,12 +73,17 @@
:- implementation.
-:- import_module parse_tree__prog_data.
-:- import_module check_hlds__type_util, check_hlds__mode_util, hlds__instmap.
:- import_module backend_libs__builtin_ops.
-:- import_module ll_backend__dense_switch, ll_backend__code_gen.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__instmap.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__tree.
+:- import_module ll_backend__code_gen.
+:- import_module ll_backend__dense_switch.
:- import_module ll_backend__exprn_aux.
-:- import_module libs__globals, libs__options, libs__tree.
+:- import_module parse_tree__prog_data.
:- import_module int, require, bool, assoc_list.
Index: compiler/loop_inv.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/loop_inv.m,v
retrieving revision 1.3
diff -u -b -r1.3 loop_inv.m
--- compiler/loop_inv.m 28 Feb 2003 00:21:37 -0000 1.3
+++ compiler/loop_inv.m 14 Mar 2003 09:22:11 -0000
@@ -99,7 +99,8 @@
:- interface.
:- import_module hlds.
-:- import_module hlds__hlds_pred, hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__hlds_module.
% hoist_loop_invariants(PredId, ProcId, PredInfo,
% ProcInfo0, ProcInfo, ModuleInfo0, ModuleInfo)
@@ -117,16 +118,21 @@
:- implementation.
-:- import_module list, assoc_list, std_util, require, set, term, string, bool.
-:- import_module parse_tree__prog_data, parse_tree__inst, parse_tree__prog_util.
-:- import_module hlds__hlds_goal, hlds__instmap, hlds__error_util.
-:- import_module hlds__quantification.
-:- import_module check_hlds.
-:- import_module check_hlds__mode_util, check_hlds__det_util.
-:- import_module check_hlds__inst_match, check_hlds__purity.
:- import_module backend_libs__code_model.
+:- import_module check_hlds.
+:- import_module check_hlds__det_util.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__purity.
+:- import_module hlds__error_util.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__instmap.
+:- import_module hlds__quantification.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_util.
-
+:- import_module list, assoc_list, std_util, require, set, term, string, bool.
:- func this_file = string.
Index: compiler/magic.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/magic.m,v
retrieving revision 1.33
diff -u -b -r1.33 magic.m
--- compiler/magic.m 28 Feb 2003 00:21:37 -0000 1.33
+++ compiler/magic.m 14 Mar 2003 09:23:37 -0000
@@ -163,6 +163,7 @@
:- interface.
:- import_module hlds__hlds_module.
+
:- import_module io.
:- pred magic__process_module(module_info, module_info, io__state, io__state).
@@ -171,15 +172,29 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module aditi_backend__magic_util, aditi_backend__context.
-:- import_module transform_hlds__dependency_graph, hlds__hlds_pred.
-:- import_module hlds__hlds_goal, hlds__hlds_data, parse_tree__prog_data.
-:- import_module hlds__passes_aux, check_hlds__mode_util, (parse_tree__inst).
-:- import_module hlds__instmap, aditi_backend__rl_gen, aditi_backend__rl.
-:- import_module libs__globals, libs__options, hlds__hlds_out.
-:- import_module parse_tree__prog_out, hlds__goal_util, check_hlds__type_util.
-:- import_module check_hlds__polymorphism, hlds__quantification.
-:- import_module ll_backend__saved_vars, transform_hlds__dead_proc_elim.
+:- import_module aditi_backend__context.
+:- import_module aditi_backend__magic_util.
+:- import_module aditi_backend__rl.
+:- import_module aditi_backend__rl_gen.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__polymorphism.
+:- import_module check_hlds__type_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_out.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module hlds__passes_aux.
+:- import_module hlds__quantification.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ll_backend__saved_vars.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
+:- import_module transform_hlds__dead_proc_elim.
+:- import_module transform_hlds__dependency_graph.
:- import_module int, list, map, require, set, std_util, string, term, varset.
:- import_module assoc_list, bool, check_hlds__simplify.
Index: compiler/magic_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/magic_util.m,v
retrieving revision 1.26
diff -u -b -r1.26 magic_util.m
--- compiler/magic_util.m 28 Feb 2003 00:21:37 -0000 1.26
+++ compiler/magic_util.m 14 Mar 2003 10:25:35 -0000
@@ -14,8 +14,11 @@
:- interface.
-:- import_module hlds__hlds_goal, hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- import_module parse_tree__prog_data.
+
:- import_module bool, io, list, map, set, std_util.
% Check that the argument types and modes are legal for
@@ -118,12 +121,19 @@
:- implementation.
-:- import_module hlds__hlds_data, ll_backend__code_util.
-:- import_module check_hlds__type_util, check_hlds__mode_util.
:- import_module check_hlds__inst_match.
-:- import_module hlds__instmap, hlds__goal_util, parse_tree__prog_out.
-:- import_module hlds__hlds_out, hlds__error_util, parse_tree__prog_util.
-:- import_module (parse_tree__inst), check_hlds__polymorphism.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__polymorphism.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_out.
+:- import_module hlds__instmap.
+:- import_module ll_backend__code_util.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
:- import_module assoc_list, int, require, string, term, varset.
Index: compiler/make.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/make.m,v
retrieving revision 1.16
diff -u -b -r1.16 make.m
--- compiler/make.m 1 Mar 2003 06:34:51 -0000 1.16
+++ compiler/make.m 14 Mar 2003 09:26:23 -0000
@@ -19,11 +19,14 @@
:- interface.
-:- include_module make__options_file, make__util.
+:- include_module make__options_file.
+:- include_module make__util.
+:- import_module make__options_file.
:- import_module parse_tree.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_io.
-:- import_module make__options_file, parse_tree__modules, parse_tree__prog_io.
:- import_module io, list.
% make__process_args(OptionArgs, NonOptionArgs).
@@ -40,22 +43,36 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- include_module make__dependencies, make__module_dep_file.
-:- include_module make__module_target, make__program_target.
-
-:- import_module hlds, libs, backend_libs.
+:- include_module make__dependencies.
+:- include_module make__module_dep_file.
+:- include_module make__module_target.
+:- include_module make__program_target.
+
+:- import_module hlds.
+:- import_module libs.
+:- import_module backend_libs.
:- import_module top_level. % XXX unwanted dependency
-:- import_module make__dependencies, make__module_dep_file.
-:- import_module make__module_target, make__program_target, make__util.
+:- import_module make__dependencies.
+:- import_module make__module_dep_file.
+:- import_module make__module_target.
+:- import_module make__program_target.
+:- import_module make__util.
-:- import_module parse_tree__prog_data, parse_tree__prog_io.
-:- import_module parse_tree__modules, parse_tree__mercury_to_mercury.
-:- import_module parse_tree__prog_out, parse_tree__prog_io_util.
-:- import_module backend_libs__foreign, backend_libs__compile_target_code.
-:- import_module libs__timestamp, libs__process_util.
-:- import_module libs__globals, libs__options, libs__handle_options.
+:- import_module backend_libs__compile_target_code.
+:- import_module backend_libs__foreign.
:- import_module hlds__error_util.
+:- import_module libs__globals.
+:- import_module libs__handle_options.
+:- import_module libs__options.
+:- import_module libs__process_util.
+:- import_module libs__timestamp.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_io_util.
+:- import_module parse_tree__prog_out.
:- import_module top_level__mercury_compile. % XXX unwanted dependency
:- import_module assoc_list, bool, char, dir, exception, getopt, int, list.
Index: compiler/make.module_dep_file.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/make.module_dep_file.m,v
retrieving revision 1.6
diff -u -b -r1.6 make.module_dep_file.m
--- compiler/make.module_dep_file.m 7 Aug 2002 13:11:51 -0000 1.6
+++ compiler/make.module_dep_file.m 14 Mar 2003 09:26:36 -0000
@@ -9,11 +9,13 @@
% Code to read and write the `<module>.module_dep' files, which contain
% information about inter-module dependencies.
%-----------------------------------------------------------------------------%
+
:- module make__module_dep_file.
:- interface.
:- import_module parse_tree__modules.
+
:- import_module std_util, io.
% Get the dependencies for a given module.
@@ -27,6 +29,7 @@
io__state::di, io__state::uo) is det.
%-----------------------------------------------------------------------------%
+
:- implementation.
get_module_dependencies(ModuleName, MaybeImports, Info0, Info) -->
Index: compiler/make.module_target.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/make.module_target.m,v
retrieving revision 1.22
diff -u -b -r1.22 make.module_target.m
--- compiler/make.module_target.m 11 Feb 2003 02:14:25 -0000 1.22
+++ compiler/make.module_target.m 14 Mar 2003 09:26:42 -0000
@@ -9,6 +9,7 @@
% Build targets which relate to a single module (e.g. C code, object code,
% interface files).
%-----------------------------------------------------------------------------%
+
:- module make__module_target.
:- interface.
Index: compiler/make.program_target.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/make.program_target.m,v
retrieving revision 1.19
diff -u -b -r1.19 make.program_target.m
--- compiler/make.program_target.m 4 Feb 2003 05:10:36 -0000 1.19
+++ compiler/make.program_target.m 14 Mar 2003 09:26:47 -0000
@@ -8,6 +8,7 @@
%
% Build targets which relate to whole programs or libraries.
%-----------------------------------------------------------------------------%
+
:- module make__program_target.
:- interface.
Index: compiler/make.util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/make.util.m,v
retrieving revision 1.14
diff -u -b -r1.14 make.util.m
--- compiler/make.util.m 1 Mar 2003 06:34:51 -0000 1.14
+++ compiler/make.util.m 14 Mar 2003 09:26:59 -0000
@@ -8,6 +8,7 @@
%
% Assorted predicates used to implement `mmc --make'.
%-----------------------------------------------------------------------------%
+
:- module make__util.
:- interface.
@@ -227,6 +228,7 @@
make_info::in, make_info::out, io__state::di, io__state::uo) is det.
%-----------------------------------------------------------------------------%
+
:- implementation.
foldl2_maybe_stop_at_error(KeepGoing, MakeTarget,
Index: compiler/make_hlds.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/make_hlds.m,v
retrieving revision 1.436
diff -u -b -r1.436 make_hlds.m
--- compiler/make_hlds.m 28 Feb 2003 06:40:41 -0000 1.436
+++ compiler/make_hlds.m 14 Mar 2003 09:27:32 -0000
@@ -22,10 +22,13 @@
:- module hlds__make_hlds.
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module parse_tree__equiv_type, parse_tree__module_qual.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_data.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- import_module hlds__special_pred.
+:- import_module parse_tree__equiv_type.
+:- import_module parse_tree__module_qual.
+:- import_module parse_tree__prog_data.
:- import_module bool, list, io, std_util.
@@ -97,25 +100,41 @@
:- implementation.
-:- import_module parse_tree__prog_io, parse_tree__prog_io_goal.
-:- import_module parse_tree__prog_io_dcg, parse_tree__prog_io_util.
-:- import_module parse_tree__prog_out, parse_tree__mercury_to_mercury.
-:- import_module parse_tree__prog_util, parse_tree__inst.
-:- import_module parse_tree__modules, parse_tree__module_qual.
-:- import_module hlds__hlds_goal, hlds__goal_util, hlds__hlds_out.
-:- import_module hlds__make_tags, hlds__quantification.
-:- import_module hlds__error_util, hlds__passes_aux.
-:- import_module check_hlds__typecheck, check_hlds__type_util.
-:- import_module check_hlds__mode_util, check_hlds__mode_errors.
-:- import_module check_hlds__clause_to_proc, check_hlds__inst_match.
-:- import_module check_hlds__purity, check_hlds__unify_proc.
-:- import_module transform_hlds__term_util.
-:- import_module ll_backend, ll_backend__llds.
-:- import_module ll_backend__fact_table.
+:- import_module backend_libs__export.
+:- import_module backend_libs__foreign.
+:- import_module check_hlds__clause_to_proc.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_errors.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__purity.
+:- import_module check_hlds__type_util.
+:- import_module check_hlds__typecheck.
+:- import_module check_hlds__unify_proc.
+:- import_module hlds__error_util.
+:- import_module hlds__goal_util.
:- import_module hlds__hlds_code_util.
-:- import_module backend_libs__export, backend_libs__foreign.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_out.
+:- import_module hlds__make_tags.
+:- import_module hlds__passes_aux.
+:- import_module hlds__quantification.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ll_backend.
+:- import_module ll_backend__fact_table.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__module_qual.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_io_dcg.
+:- import_module parse_tree__prog_io_goal.
+:- import_module parse_tree__prog_io_util.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
:- import_module recompilation.
-:- import_module libs__options, libs__globals.
+:- import_module transform_hlds__term_util.
:- import_module string, char, int, set, map, multi_map, require.
:- import_module bag, term, varset, getopt, assoc_list, term_io.
Index: compiler/make_tags.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/make_tags.m,v
retrieving revision 1.38
diff -u -b -r1.38 make_tags.m
--- compiler/make_tags.m 14 Jan 2003 16:42:27 -0000 1.38
+++ compiler/make_tags.m 14 Mar 2003 09:27:48 -0000
@@ -58,7 +58,10 @@
:- module hlds__make_tags.
:- interface.
-:- import_module parse_tree__prog_data, hlds__hlds_data, libs__globals.
+:- import_module hlds__hlds_data.
+:- import_module libs__globals.
+:- import_module parse_tree__prog_data.
+
:- import_module bool, list.
% assign_constructor_tags(Constructors, TypeCtor, ReservedTagPragma, Globals,
@@ -77,8 +80,12 @@
:- implementation.
-:- import_module parse_tree__prog_util, check_hlds__type_util.
-:- import_module hlds__error_util, libs__globals, libs__options.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__prog_util.
+
:- import_module int, map, std_util, require.
%-----------------------------------------------------------------------------%
Index: compiler/mark_static_terms.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mark_static_terms.m,v
retrieving revision 1.9
diff -u -b -r1.9 mark_static_terms.m
--- compiler/mark_static_terms.m 28 Mar 2002 03:43:16 -0000 1.9
+++ compiler/mark_static_terms.m 14 Mar 2003 09:28:00 -0000
@@ -18,7 +18,8 @@
:- interface.
-:- import_module hlds__hlds_pred, hlds__hlds_module.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- pred mark_static_terms(proc_info::in, module_info::in, proc_info::out)
is det.
@@ -26,7 +27,11 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module parse_tree__prog_data, hlds__hlds_goal, hlds__hlds_data.
+
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module parse_tree__prog_data.
+
:- import_module map, list, bool.
%
Index: compiler/matching.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/matching.m,v
retrieving revision 1.1
diff -u -b -r1.1 matching.m
--- compiler/matching.m 28 Mar 2002 03:43:16 -0000 1.1
+++ compiler/matching.m 14 Mar 2003 09:28:10 -0000
@@ -16,6 +16,7 @@
:- module backend_libs__matching.
:- interface.
+
:- import_module parse_tree__prog_data.
:- import_module bool, list, set.
Index: compiler/maybe_mlds_to_gcc.pp
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/maybe_mlds_to_gcc.pp,v
retrieving revision 1.5
diff -u -b -r1.5 maybe_mlds_to_gcc.pp
--- compiler/maybe_mlds_to_gcc.pp 20 Mar 2002 12:35:47 -0000 1.5
+++ compiler/maybe_mlds_to_gcc.pp 14 Mar 2003 15:37:36 -0000
@@ -17,7 +17,9 @@
:- module ml_backend__maybe_mlds_to_gcc.
:- interface.
-:- import_module ml_backend__mlds, bool.
+:- import_module ml_backend__mlds.
+
+:- import_module bool.
:- use_module io.
:- type frontend_callback(T) == pred(T, io__state, io__state).
Index: compiler/mercury_compile.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mercury_compile.m,v
retrieving revision 1.279
diff -u -b -r1.279 mercury_compile.m
--- compiler/mercury_compile.m 5 Mar 2003 10:50:06 -0000 1.279
+++ compiler/mercury_compile.m 14 Mar 2003 09:31:52 -0000
@@ -39,48 +39,75 @@
%
% semantic analysis
-:- import_module libs__handle_options, parse_tree__prog_io.
-:- import_module parse_tree__prog_out, parse_tree__modules.
-:- import_module parse_tree__source_file_map, parse_tree__module_qual.
-:- import_module parse_tree__equiv_type, hlds__make_hlds.
-:- import_module check_hlds__typecheck, check_hlds__purity.
-:- import_module check_hlds__polymorphism, check_hlds__modes.
-:- import_module check_hlds__switch_detection, check_hlds__cse_detection.
-:- import_module check_hlds__det_analysis, check_hlds__unique_modes.
-:- import_module check_hlds__stratify, check_hlds__simplify.
+:- import_module libs__handle_options.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__source_file_map.
+:- import_module parse_tree__module_qual.
+:- import_module parse_tree__equiv_type.
+:- import_module hlds__make_hlds.
+:- import_module check_hlds__typecheck.
+:- import_module check_hlds__purity.
+:- import_module check_hlds__polymorphism.
+:- import_module check_hlds__modes.
+:- import_module check_hlds__switch_detection.
+:- import_module check_hlds__cse_detection.
+:- import_module check_hlds__det_analysis.
+:- import_module check_hlds__unique_modes.
+:- import_module check_hlds__stratify.
+:- import_module check_hlds__simplify.
% high-level HLDS transformations
-:- import_module check_hlds__check_typeclass, transform_hlds__intermod.
-:- import_module transform_hlds__trans_opt, transform_hlds__table_gen.
+:- import_module check_hlds__check_typeclass.
+:- import_module transform_hlds__intermod.
+:- import_module transform_hlds__trans_opt.
+:- import_module transform_hlds__table_gen.
:- import_module transform_hlds__lambda.
-:- import_module backend_libs__type_ctor_info, transform_hlds__termination.
-:- import_module transform_hlds__higher_order, transform_hlds__accumulator.
-:- import_module transform_hlds__inlining, transform_hlds__loop_inv.
+:- import_module backend_libs__type_ctor_info.
+:- import_module transform_hlds__termination.
+:- import_module transform_hlds__higher_order.
+:- import_module transform_hlds__accumulator.
+:- import_module transform_hlds__inlining.
+:- import_module transform_hlds__loop_inv.
:- import_module transform_hlds__deforest.
-:- import_module aditi_backend__dnf, aditi_backend__magic.
+:- import_module aditi_backend__dnf.
+:- import_module aditi_backend__magic.
:- import_module transform_hlds__dead_proc_elim.
-:- import_module transform_hlds__delay_construct, transform_hlds__unused_args.
-:- import_module transform_hlds__unneeded_code, transform_hlds__lco.
+:- import_module transform_hlds__delay_construct.
+:- import_module transform_hlds__unused_args.
+:- import_module transform_hlds__unneeded_code.
+:- import_module transform_hlds__lco.
:- import_module ll_backend__deep_profiling.
% the LLDS back-end
-:- import_module ll_backend__saved_vars, ll_backend__stack_opt.
-:- import_module ll_backend__stack_alloc, ll_backend__follow_code.
-:- import_module ll_backend__liveness, ll_backend__live_vars.
-:- import_module ll_backend__arg_info, ll_backend__store_alloc.
-:- import_module ll_backend__code_gen, ll_backend__optimize.
-:- import_module ll_backend__llds_common, ll_backend__transform_llds.
+:- import_module ll_backend__saved_vars.
+:- import_module ll_backend__stack_opt.
+:- import_module ll_backend__stack_alloc.
+:- import_module ll_backend__follow_code.
+:- import_module ll_backend__liveness.
+:- import_module ll_backend__live_vars.
+:- import_module ll_backend__arg_info.
+:- import_module ll_backend__store_alloc.
+:- import_module ll_backend__code_gen.
+:- import_module ll_backend__optimize.
+:- import_module ll_backend__llds_common.
+:- import_module ll_backend__transform_llds.
:- import_module ll_backend__llds_out.
-:- import_module ll_backend__continuation_info, ll_backend__stack_layout.
-:- import_module backend_libs__foreign, backend_libs__export.
+:- import_module ll_backend__continuation_info.
+:- import_module ll_backend__stack_layout.
+:- import_module backend_libs__foreign.
+:- import_module backend_libs__export.
:- import_module backend_libs__base_typeclass_info.
% the Aditi-RL back-end
-:- import_module aditi_backend__rl_gen, aditi_backend__rl_opt.
+:- import_module aditi_backend__rl_gen.
+:- import_module aditi_backend__rl_opt.
:- import_module aditi_backend__rl_out.
% the bytecode back-end
-:- import_module bytecode_backend__bytecode_gen, bytecode_backend__bytecode.
+:- import_module bytecode_backend__bytecode_gen.
+:- import_module bytecode_backend__bytecode.
% the MLDS back-end
:- import_module ml_backend__add_trail_ops. % HLDS -> HLDS
@@ -99,19 +126,31 @@
:- import_module ml_backend__ml_util. % MLDS utility predicates
% miscellaneous compiler modules
-:- import_module parse_tree__prog_data, hlds__hlds_module, hlds__hlds_pred.
-:- import_module hlds__hlds_out, ll_backend__llds, aditi_backend__rl.
-:- import_module parse_tree__mercury_to_mercury, hlds__hlds_data.
-:- import_module ll_backend__layout, transform_hlds__dependency_graph.
-:- import_module parse_tree__prog_util, aditi_backend__rl_dump.
+:- import_module parse_tree__prog_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__hlds_out.
+:- import_module ll_backend__llds.
+:- import_module aditi_backend__rl.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module hlds__hlds_data.
+:- import_module ll_backend__layout.
+:- import_module transform_hlds__dependency_graph.
+:- import_module parse_tree__prog_util.
+:- import_module aditi_backend__rl_dump.
:- import_module aditi_backend__rl_file.
-:- import_module libs__options, libs__globals, libs__trace_params.
+:- import_module libs__options.
+:- import_module libs__globals.
+:- import_module libs__trace_params.
:- import_module check_hlds__goal_path.
:- import_module hlds__passes_aux.
-:- import_module recompilation, recompilation__usage.
+:- import_module recompilation.
+:- import_module recompilation__usage.
:- import_module recompilation__check.
:- import_module libs__timestamp.
-:- import_module make, make__options_file, make__util.
+:- import_module make.
+:- import_module make__options_file.
+:- import_module make__util.
:- import_module backend_libs__compile_target_code.
% inter-module analysis framework
Index: compiler/mercury_to_mercury.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mercury_to_mercury.m,v
retrieving revision 1.226
diff -u -b -r1.226 mercury_to_mercury.m
--- compiler/mercury_to_mercury.m 3 Mar 2003 03:25:13 -0000 1.226
+++ compiler/mercury_to_mercury.m 14 Mar 2003 09:32:21 -0000
@@ -42,9 +42,12 @@
:- module parse_tree__mercury_to_mercury.
:- interface.
-:- import_module parse_tree__prog_data, (parse_tree__inst).
-:- import_module hlds__hlds_goal, hlds__hlds_data, hlds__hlds_module.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
:- import_module libs__globals.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
:- import_module bool, std_util, list, io, varset, term.
@@ -352,14 +355,20 @@
:- implementation.
-:- import_module parse_tree__prog_out, parse_tree__prog_util, hlds__hlds_pred.
+:- import_module backend_libs__foreign.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__purity.
+:- import_module hlds__hlds_out.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module libs__globals.
+:- import_module libs__options.
:- import_module parse_tree__prog_io_util.
-:- import_module hlds__hlds_out, hlds__instmap.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
:- import_module recompilation__version.
-:- import_module check_hlds__purity, check_hlds__mode_util.
:- import_module transform_hlds__term_util.
-:- import_module libs__globals, libs__options, transform_hlds__termination.
-:- import_module backend_libs__foreign.
+:- import_module transform_hlds__termination.
:- import_module assoc_list, char, int, string, set, lexer, ops, require.
:- import_module term, term_io, varset.
Index: compiler/middle_rec.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/middle_rec.m,v
retrieving revision 1.91
diff -u -b -r1.91 middle_rec.m
--- compiler/middle_rec.m 7 May 2002 11:03:01 -0000 1.91
+++ compiler/middle_rec.m 14 Mar 2003 09:32:45 -0000
@@ -14,7 +14,9 @@
:- interface.
-:- import_module hlds__hlds_goal, ll_backend__llds, ll_backend__code_info.
+:- import_module hlds__hlds_goal.
+:- import_module ll_backend__code_info.
+:- import_module ll_backend__llds.
:- pred middle_rec__match_and_generate(hlds_goal, code_tree,
code_info, code_info).
@@ -25,14 +27,20 @@
:- implementation.
-:- import_module parse_tree__prog_data, parse_tree__prog_out.
-:- import_module hlds__hlds_module, hlds__hlds_data, hlds__goal_form.
+:- import_module backend_libs__builtin_ops.
+:- import_module backend_libs__code_model.
+:- import_module hlds__goal_form.
+:- import_module hlds__hlds_data.
:- import_module hlds__hlds_llds.
-:- import_module ll_backend__code_gen, ll_backend__unify_gen.
-:- import_module ll_backend__code_util, ll_backend__opt_util.
-:- import_module ll_backend__code_aux.
-:- import_module backend_libs__builtin_ops, backend_libs__code_model.
+:- import_module hlds__hlds_module.
:- import_module libs__tree.
+:- import_module ll_backend__code_aux.
+:- import_module ll_backend__code_gen.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__opt_util.
+:- import_module ll_backend__unify_gen.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
:- import_module bool, int, string, list, assoc_list, set, std_util.
:- import_module require.
Index: compiler/ml_backend.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ml_backend.m,v
retrieving revision 1.2
diff -u -b -r1.2 ml_backend.m
--- compiler/ml_backend.m 21 Jun 2002 13:26:39 -0000 1.2
+++ compiler/ml_backend.m 14 Mar 2003 10:26:50 -0000
@@ -21,9 +21,14 @@
%
:- module ml_backend.
:- interface.
-:- import_module transform_hlds, check_hlds. % are these needed?
-:- import_module hlds, parse_tree, libs, backend_libs.
+
+:- import_module backend_libs.
+:- import_module check_hlds. % is this needed?
+:- import_module hlds.
+:- import_module libs.
:- import_module ll_backend. % XXX needed for llds_out__name_mangle, etc.
+:- import_module parse_tree.
+:- import_module transform_hlds. % is this needed?
%-----------------------------------------------------------------------------%
@@ -31,23 +36,27 @@
:- include_module ml_util.
% Phase 4-ml: MLDS-specific HLDS to HLDS transformations and annotations.
-:- include_module add_heap_ops, add_trail_ops. % transformations
+:- include_module add_heap_ops.
+:- include_module add_trail_ops. % transformations
:- include_module mark_static_terms. % annotation
% Phase 5-ml: compile HLDS to MLDS
:- include_module ml_code_gen.
- :- include_module ml_type_gen.
:- include_module ml_call_gen.
- :- include_module ml_unify_gen, ml_closure_gen.
+ :- include_module ml_closure_gen.
:- include_module ml_switch_gen.
- :- include_module ml_string_switch, ml_tag_switch, ml_simplify_switch.
+ :- include_module ml_simplify_switch.
+ :- include_module ml_string_switch.
+ :- include_module ml_tag_switch.
+ :- include_module ml_type_gen.
+ :- include_module ml_unify_gen.
:- include_module ml_code_util.
:- include_module rtti_to_mlds.
% Phase 6-ml: MLDS -> MLDS transformations
:- include_module ml_elim_nested.
-:- include_module ml_tailcall.
:- include_module ml_optimize.
+:- include_module ml_tailcall.
% Phase 7-ml: compile MLDS to target code
@@ -59,15 +68,16 @@
% :- include_module mlds_to_gcc, gcc.
% MLDS->Java back-end
-:- include_module mlds_to_java, java_util.
+:- include_module mlds_to_java.
+:- include_module java_util.
% MLDS->.NET CLR back-end
+:- include_module il_peephole.
+:- include_module ilasm.
+:- include_module ilds.
:- include_module mlds_to_il.
:- include_module mlds_to_ilasm.
:- include_module mlds_to_managed.
-:- include_module ilds.
-:- include_module ilasm.
-:- include_module il_peephole.
:- end_module ml_backend.
Index: compiler/ml_call_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ml_call_gen.m,v
retrieving revision 1.38
diff -u -b -r1.38 ml_call_gen.m
--- compiler/ml_call_gen.m 14 Feb 2003 09:59:21 -0000 1.38
+++ compiler/ml_call_gen.m 14 Mar 2003 09:34:48 -0000
@@ -16,10 +16,12 @@
:- module ml_backend__ml_call_gen.
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_pred, hlds__hlds_goal.
:- import_module backend_libs__code_model.
-:- import_module ml_backend__mlds, ml_backend__ml_code_util.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_pred.
+:- import_module ml_backend__ml_code_util.
+:- import_module ml_backend__mlds.
+:- import_module parse_tree__prog_data.
:- import_module list, bool.
@@ -113,12 +115,15 @@
:- implementation.
-:- import_module ml_backend__ml_closure_gen.
-:- import_module hlds__hlds_module, hlds__hlds_data.
:- import_module backend_libs__builtin_ops.
-:- import_module check_hlds__type_util, check_hlds__mode_util.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
:- import_module hlds__error_util.
-:- import_module libs__options, libs__globals.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ml_backend__ml_closure_gen.
:- import_module bool, int, string, std_util, term, varset, require, map.
Index: compiler/ml_closure_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ml_closure_gen.m,v
retrieving revision 1.14
diff -u -b -r1.14 ml_closure_gen.m
--- compiler/ml_closure_gen.m 27 Jan 2003 09:20:48 -0000 1.14
+++ compiler/ml_closure_gen.m 14 Mar 2003 09:35:45 -0000
@@ -15,9 +15,11 @@
:- module ml_backend__ml_closure_gen.
:- interface.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_pred.
+:- import_module ml_backend__ml_code_util.
+:- import_module ml_backend__mlds.
:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_pred, hlds__hlds_goal.
-:- import_module ml_backend__mlds, ml_backend__ml_code_util.
:- import_module list.
@@ -72,21 +74,26 @@
:- implementation.
-:- import_module hlds__hlds_module.
-:- import_module backend_libs__code_model, backend_libs__pseudo_type_info.
+:- import_module backend_libs__code_model.
+:- import_module backend_libs__pseudo_type_info.
:- import_module backend_libs__rtti.
-:- import_module ml_backend__ml_unify_gen, ml_backend__ml_call_gen.
-:- import_module ml_backend__rtti_to_mlds.
-:- import_module check_hlds__type_util, check_hlds__mode_util.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
:- import_module hlds__error_util.
-:- import_module libs__options, libs__globals.
+:- import_module hlds__hlds_module.
+:- import_module libs__globals.
+:- import_module libs__options.
% XXX The following modules depend on the LLDS,
% so ideally they should not be used here.
:- import_module ll_backend__continuation_info. % needed for
% `generate_closure_layout'
-:- import_module ll_backend__stack_layout. % needed for `represent_locn_as_int'
:- import_module ll_backend__llds. % needed for `layout_locn'
+:- import_module ll_backend__stack_layout. % needed for `represent_locn_as_int'
+
+:- import_module ml_backend__ml_call_gen.
+:- import_module ml_backend__ml_unify_gen.
+:- import_module ml_backend__rtti_to_mlds.
:- import_module assoc_list, bool, int, map, set, std_util, string, term.
Index: compiler/ml_code_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ml_code_gen.m,v
retrieving revision 1.127
diff -u -b -r1.127 ml_code_gen.m
--- compiler/ml_code_gen.m 3 Mar 2003 14:33:15 -0000 1.127
+++ compiler/ml_code_gen.m 14 Mar 2003 09:36:12 -0000
@@ -723,10 +723,13 @@
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_module, hlds__hlds_goal.
:- import_module backend_libs__code_model.
-:- import_module ml_backend__mlds, ml_backend__ml_code_util.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module ml_backend__ml_code_util.
+:- import_module ml_backend__mlds.
+:- import_module parse_tree__prog_data.
+
:- import_module io, map.
%-----------------------------------------------------------------------------%
@@ -780,18 +783,25 @@
:- implementation.
-:- import_module ml_backend__ml_type_gen, ml_backend__ml_call_gen.
-:- import_module ml_backend__ml_unify_gen, ml_backend__ml_switch_gen.
-:- import_module ml_backend__ml_code_util.
+:- import_module backend_libs__builtin_ops.
+:- import_module backend_libs__c_util.
:- import_module backend_libs__export.
:- import_module backend_libs__foreign. % XXX needed for pragma foreign code
-:- import_module hlds__hlds_pred, hlds__hlds_data.
-:- import_module hlds__goal_util, check_hlds__type_util.
-:- import_module check_hlds__mode_util, backend_libs__builtin_ops.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
:- import_module hlds__error_util.
-:- import_module backend_libs__c_util.
-:- import_module hlds__passes_aux, parse_tree__modules.
-:- import_module libs__globals, libs__options.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ml_backend__ml_call_gen.
+:- import_module ml_backend__ml_code_util.
+:- import_module ml_backend__ml_switch_gen.
+:- import_module ml_backend__ml_type_gen.
+:- import_module ml_backend__ml_unify_gen.
+:- import_module parse_tree__modules.
:- import_module assoc_list, bool, string, list.
:- import_module int, set, term, require, std_util.
Index: compiler/ml_elim_nested.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ml_elim_nested.m,v
retrieving revision 1.60
diff -u -b -r1.60 ml_elim_nested.m
--- compiler/ml_elim_nested.m 3 Mar 2003 14:33:16 -0000 1.60
+++ compiler/ml_elim_nested.m 14 Mar 2003 09:37:04 -0000
@@ -435,6 +435,7 @@
:- interface.
:- import_module ml_backend__mlds.
+
:- import_module io.
%-----------------------------------------------------------------------------%
@@ -453,15 +454,21 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module bool, counter, int, list, std_util, string, require.
-:- import_module ml_backend__ml_code_util, ml_backend__ml_util.
-:- import_module parse_tree__prog_util, check_hlds__type_util.
+:- import_module check_hlds__type_util.
+:- import_module ml_backend__ml_code_util.
+:- import_module ml_backend__ml_util.
+:- import_module parse_tree__prog_util.
% the following imports are needed for mangling pred names
-:- import_module hlds__hlds_pred, parse_tree__prog_data, parse_tree__prog_out.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
-:- import_module libs__globals, libs__options.
+:- import_module libs__globals.
+:- import_module libs__options.
+
+:- import_module bool, counter, int, list, std_util, string, require.
% Perform the specified action on the whole MLDS.
%
Index: compiler/ml_optimize.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ml_optimize.m,v
retrieving revision 1.21
diff -u -b -r1.21 ml_optimize.m
--- compiler/ml_optimize.m 21 Jun 2002 13:26:41 -0000 1.21
+++ compiler/ml_optimize.m 14 Mar 2003 09:37:21 -0000
@@ -32,7 +32,9 @@
:- module ml_backend__ml_optimize.
:- interface.
-:- import_module ml_backend__mlds, io.
+:- import_module ml_backend__mlds.
+
+:- import_module io.
:- pred optimize(mlds, mlds, io__state, io__state).
:- mode optimize(in, out, di, uo) is det.
@@ -41,10 +43,14 @@
:- implementation.
-:- import_module ml_backend__ml_util, ml_backend__ml_code_util.
-:- import_module parse_tree__prog_data, parse_tree__prog_util.
-:- import_module backend_libs__builtin_ops, libs__globals, libs__options.
+:- import_module backend_libs__builtin_ops.
:- import_module hlds__error_util.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ml_backend__ml_code_util.
+:- import_module ml_backend__ml_util.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_util.
:- import_module bool, int, list, require, std_util, string.
Index: compiler/ml_simplify_switch.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ml_simplify_switch.m,v
retrieving revision 1.6
diff -u -b -r1.6 ml_simplify_switch.m
--- compiler/ml_simplify_switch.m 20 Mar 2002 12:36:47 -0000 1.6
+++ compiler/ml_simplify_switch.m 14 Mar 2003 09:37:37 -0000
@@ -23,19 +23,21 @@
:- module ml_backend__ml_simplify_switch.
:- interface.
-:- import_module ml_backend__mlds, ml_backend__ml_code_util.
+:- import_module ml_backend__mlds.
+:- import_module ml_backend__ml_code_util.
:- pred ml_simplify_switch(mlds__stmt::in, mlds__context::in,
- mlds__statement::out,
- ml_gen_info::in, ml_gen_info::out) is det.
+ mlds__statement::out, ml_gen_info::in, ml_gen_info::out) is det.
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module ml_backend__ml_switch_gen, backend_libs__builtin_ops.
+:- import_module backend_libs__builtin_ops.
:- import_module check_hlds__type_util.
-:- import_module libs__globals, libs__options.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ml_backend__ml_switch_gen.
:- import_module bool, int, list, map, require, std_util.
Index: compiler/ml_string_switch.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ml_string_switch.m,v
retrieving revision 1.12
diff -u -b -r1.12 ml_string_switch.m
--- compiler/ml_string_switch.m 27 Sep 2002 06:59:17 -0000 1.12
+++ compiler/ml_string_switch.m 14 Mar 2003 09:37:52 -0000
@@ -19,10 +19,12 @@
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_data, backend_libs__switch_util.
:- import_module backend_libs__code_model.
-:- import_module ml_backend__mlds, ml_backend__ml_code_util.
+:- import_module backend_libs__switch_util.
+:- import_module hlds__hlds_data.
+:- import_module ml_backend__ml_code_util.
+:- import_module ml_backend__mlds.
+:- import_module parse_tree__prog_data.
:- pred ml_string_switch__generate(cases_list::in, prog_var::in,
code_model::in, can_fail::in, prog_context::in,
@@ -33,10 +35,13 @@
:- implementation.
-:- import_module ml_backend__ml_code_gen, ml_backend__ml_switch_gen.
+:- import_module backend_libs__builtin_ops.
+:- import_module check_hlds__type_util.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ml_backend__ml_code_gen.
:- import_module ml_backend__ml_simplify_switch.
-:- import_module backend_libs__builtin_ops, check_hlds__type_util.
-:- import_module libs__globals, libs__options.
+:- import_module ml_backend__ml_switch_gen.
:- import_module bool, int, string, list, map, std_util, assoc_list, require.
Index: compiler/ml_switch_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ml_switch_gen.m,v
retrieving revision 1.11
diff -u -b -r1.11 ml_switch_gen.m
--- compiler/ml_switch_gen.m 20 Mar 2002 12:36:47 -0000 1.11
+++ compiler/ml_switch_gen.m 14 Mar 2003 09:38:11 -0000
@@ -62,11 +62,13 @@
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_goal, hlds__hlds_data.
:- import_module backend_libs__code_model.
-:- import_module ml_backend__mlds, ml_backend__ml_code_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
:- import_module libs__globals.
+:- import_module ml_backend__ml_code_util.
+:- import_module ml_backend__mlds.
+:- import_module parse_tree__prog_data.
:- import_module list.
@@ -96,11 +98,16 @@
:- implementation.
-:- import_module ml_backend__ml_tag_switch, ml_backend__ml_string_switch.
-:- import_module ml_backend__ml_code_gen, ml_backend__ml_unify_gen.
-:- import_module ml_backend__ml_code_util, ml_backend__ml_simplify_switch.
-:- import_module backend_libs__switch_util, check_hlds__type_util.
-:- import_module backend_libs__foreign, libs__options.
+:- import_module backend_libs__foreign.
+:- import_module backend_libs__switch_util.
+:- import_module check_hlds__type_util.
+:- import_module libs__options.
+:- import_module ml_backend__ml_code_gen.
+:- import_module ml_backend__ml_code_util.
+:- import_module ml_backend__ml_simplify_switch.
+:- import_module ml_backend__ml_string_switch.
+:- import_module ml_backend__ml_tag_switch.
+:- import_module ml_backend__ml_unify_gen.
:- import_module bool, int, string, map, libs__tree, std_util, require.
Index: compiler/ml_tag_switch.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ml_tag_switch.m,v
retrieving revision 1.5
diff -u -b -r1.5 ml_tag_switch.m
--- compiler/ml_tag_switch.m 20 Mar 2002 12:36:47 -0000 1.5
+++ compiler/ml_tag_switch.m 14 Mar 2003 09:38:26 -0000
@@ -15,10 +15,12 @@
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_data, backend_libs__switch_util.
:- import_module backend_libs__code_model.
-:- import_module ml_backend__mlds, ml_backend__ml_code_util.
+:- import_module backend_libs__switch_util.
+:- import_module hlds__hlds_data.
+:- import_module ml_backend__ml_code_util.
+:- import_module ml_backend__mlds.
+:- import_module parse_tree__prog_data.
:- import_module list.
@@ -31,10 +33,14 @@
:- implementation.
-:- import_module hlds__hlds_goal, hlds__hlds_module.
-:- import_module ml_backend__ml_code_gen, ml_backend__ml_switch_gen.
-:- import_module ml_backend__ml_unify_gen, ml_backend__ml_simplify_switch.
-:- import_module backend_libs__builtin_ops, check_hlds__type_util.
+:- import_module backend_libs__builtin_ops.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module ml_backend__ml_code_gen.
+:- import_module ml_backend__ml_simplify_switch.
+:- import_module ml_backend__ml_switch_gen.
+:- import_module ml_backend__ml_unify_gen.
:- import_module assoc_list, map, int, string, require, std_util.
Index: compiler/ml_tailcall.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ml_tailcall.m,v
retrieving revision 1.18
diff -u -b -r1.18 ml_tailcall.m
--- compiler/ml_tailcall.m 21 Sep 2002 09:48:43 -0000 1.18
+++ compiler/ml_tailcall.m 14 Mar 2003 09:38:40 -0000
@@ -56,7 +56,9 @@
:- module ml_backend__ml_tailcall.
:- interface.
+
:- import_module ml_backend__mlds.
+
:- import_module io.
% Traverse the MLDS, marking all optimizable tail calls
@@ -75,8 +77,13 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module parse_tree__prog_data, hlds__hlds_pred, hlds__hlds_out.
-:- import_module hlds__error_util, ml_backend__ml_util.
+
+:- import_module hlds__error_util.
+:- import_module hlds__hlds_out.
+:- import_module hlds__hlds_pred.
+:- import_module ml_backend__ml_util.
+:- import_module parse_tree__prog_data.
+
:- import_module string, int, list, std_util.
ml_mark_tailcalls(MLDS0, MLDS) -->
Index: compiler/ml_type_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ml_type_gen.m,v
retrieving revision 1.31
diff -u -b -r1.31 ml_type_gen.m
--- compiler/ml_type_gen.m 12 Feb 2003 22:58:10 -0000 1.31
+++ compiler/ml_type_gen.m 14 Mar 2003 09:39:03 -0000
@@ -25,8 +25,12 @@
:- module ml_backend__ml_type_gen.
:- interface.
-:- import_module parse_tree__prog_data, hlds__hlds_module, hlds__hlds_data.
+
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
:- import_module ml_backend__mlds.
+:- import_module parse_tree__prog_data.
+
:- import_module io.
% Generate MLDS definitions for all the types in the HLDS.
@@ -74,12 +78,17 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module hlds__hlds_pred, parse_tree__prog_data.
-:- import_module parse_tree__prog_util, check_hlds__type_util.
+
:- import_module check_hlds__polymorphism.
-:- import_module ml_backend__ml_code_util, hlds__error_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module hlds__hlds_pred.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ml_backend__ml_code_util.
:- import_module ml_backend__ml_util.
-:- import_module libs__globals, libs__options.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_util.
:- import_module bool, int, string, list, map, std_util, term, require.
Index: compiler/ml_unify_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ml_unify_gen.m,v
retrieving revision 1.62
diff -u -b -r1.62 ml_unify_gen.m
--- compiler/ml_unify_gen.m 14 Feb 2003 13:34:48 -0000 1.62
+++ compiler/ml_unify_gen.m 14 Mar 2003 09:40:24 -0000
@@ -15,10 +15,13 @@
:- module ml_backend__ml_unify_gen.
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_module, hlds__hlds_data, hlds__hlds_goal.
:- import_module backend_libs__code_model.
-:- import_module ml_backend__mlds, ml_backend__ml_code_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module ml_backend__ml_code_util.
+:- import_module ml_backend__mlds.
+:- import_module parse_tree__prog_data.
:- import_module bool, list, std_util.
@@ -83,14 +86,21 @@
:- implementation.
-:- import_module hlds__hlds_pred, hlds__hlds_out, backend_libs__builtin_ops.
-:- import_module ml_backend__ml_code_gen, ml_backend__ml_call_gen.
-:- import_module ml_backend__ml_type_gen, ml_backend__ml_closure_gen.
-:- import_module ml_backend__ml_util.
-:- import_module parse_tree__prog_util, check_hlds__type_util.
+:- import_module backend_libs__builtin_ops.
+:- import_module backend_libs__rtti.
:- import_module check_hlds__mode_util.
-:- import_module backend_libs__rtti, hlds__error_util.
-:- import_module libs__globals, libs__options.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module hlds__hlds_out.
+:- import_module hlds__hlds_pred.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ml_backend__ml_call_gen.
+:- import_module ml_backend__ml_closure_gen.
+:- import_module ml_backend__ml_code_gen.
+:- import_module ml_backend__ml_type_gen.
+:- import_module ml_backend__ml_util.
+:- import_module parse_tree__prog_util.
% XXX The following modules depend on the LLDS,
% so ideally they should not be used here.
Index: compiler/ml_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/ml_util.m,v
retrieving revision 1.23
diff -u -b -r1.23 ml_util.m
--- compiler/ml_util.m 27 Nov 2002 13:30:19 -0000 1.23
+++ compiler/ml_util.m 14 Mar 2003 09:40:46 -0000
@@ -14,10 +14,11 @@
:- module ml_backend__ml_util.
:- interface.
+:- import_module libs__globals. % for foreign_language
:- import_module ml_backend__mlds.
:- import_module parse_tree__prog_data.
+
:- import_module list, std_util.
-:- import_module libs__globals. % for foreign_language
%-----------------------------------------------------------------------------%
% succeeds iff the definitions contain the entry point to
@@ -161,8 +162,10 @@
:- implementation.
:- import_module backend_libs__rtti.
-:- import_module parse_tree__prog_io, parse_tree__prog_util.
:- import_module check_hlds__type_util.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_util.
+
:- import_module bool, list, std_util.
%-----------------------------------------------------------------------------%
Index: compiler/mlds.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mlds.m,v
retrieving revision 1.98
diff -u -b -r1.98 mlds.m
--- compiler/mlds.m 12 Feb 2003 22:58:10 -0000 1.98
+++ compiler/mlds.m 14 Mar 2003 09:41:18 -0000
@@ -287,11 +287,16 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_data.
-:- import_module parse_tree__prog_data, backend_libs__builtin_ops.
-:- import_module backend_libs__rtti, backend_libs__code_model.
-:- import_module backend_libs__foreign, check_hlds__type_util.
+:- import_module backend_libs__builtin_ops.
+:- import_module backend_libs__code_model.
+:- import_module backend_libs__foreign.
+:- import_module backend_libs__rtti.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- import_module libs__globals.
+:- import_module parse_tree__prog_data.
:- import_module bool, list, std_util, map.
@@ -1654,8 +1659,12 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module backend_libs__foreign, parse_tree__modules.
-:- import_module hlds__error_util, libs__globals.
+
+:- import_module backend_libs__foreign.
+:- import_module hlds__error_util.
+:- import_module libs__globals.
+:- import_module parse_tree__modules.
+
:- import_module int, term, string, require.
%-----------------------------------------------------------------------------%
Index: compiler/mlds_to_c.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mlds_to_c.m,v
retrieving revision 1.143
diff -u -b -r1.143 mlds_to_c.m
--- compiler/mlds_to_c.m 26 Feb 2003 06:36:24 -0000 1.143
+++ compiler/mlds_to_c.m 14 Mar 2003 09:42:35 -0000
@@ -24,6 +24,7 @@
:- interface.
:- import_module ml_backend__mlds.
+
:- import_module io.
% output_mlds(MLDS, Suffix):
@@ -62,25 +63,30 @@
:- implementation.
-:- import_module ml_backend__ml_util.
+:- import_module backend_libs__builtin_ops.
+:- import_module backend_libs__c_util.
+:- import_module backend_libs__code_model.
+:- import_module backend_libs__foreign.
+:- import_module backend_libs__rtti. % for rtti__addr_to_string.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module hlds__hlds_pred. % for pred_proc_id.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
:- import_module ll_backend__llds_out. % XXX needed for llds_out__name_mangle,
% llds_out__sym_name_mangle,
% llds_out__make_base_typeclass_info_name,
% output_c_file_intro_and_grade.
-:- import_module backend_libs__rtti. % for rtti__addr_to_string.
-:- import_module ml_backend__rtti_to_mlds. % for mlds_rtti_type_name.
-:- import_module hlds__hlds_pred. % for pred_proc_id.
:- import_module ml_backend__ml_code_util.
% for ml_gen_public_field_decl_flags, which is
% used by the code that handles derived classes
:- import_module ml_backend__ml_type_gen. % for ml_gen_type_name
-:- import_module backend_libs__foreign.
-:- import_module libs__globals, libs__options, hlds__passes_aux.
-:- import_module backend_libs__builtin_ops, backend_libs__c_util.
+:- import_module ml_backend__ml_util.
+:- import_module ml_backend__rtti_to_mlds. % for mlds_rtti_type_name.
:- import_module parse_tree__modules.
-:- import_module parse_tree__prog_data, parse_tree__prog_out.
-:- import_module check_hlds__type_util, hlds__error_util.
-:- import_module backend_libs__code_model.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
:- import_module bool, int, string, library, list, map.
:- import_module assoc_list, term, std_util, require.
Index: compiler/mlds_to_gcc.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mlds_to_gcc.m,v
retrieving revision 1.80
diff -u -b -r1.80 mlds_to_gcc.m
--- compiler/mlds_to_gcc.m 26 Feb 2003 06:36:24 -0000 1.80
+++ compiler/mlds_to_gcc.m 14 Mar 2003 09:43:53 -0000
@@ -92,7 +92,10 @@
:- interface.
:- import_module ml_backend.
-:- import_module ml_backend__mlds, ml_backend__maybe_mlds_to_gcc, bool.
+:- import_module ml_backend__maybe_mlds_to_gcc.
+:- import_module ml_backend__mlds.
+
+:- import_module bool.
:- use_module io.
% run_gcc_backend(ModuleName, CallBack, CallBackOutput):
@@ -143,30 +146,38 @@
:- implementation.
:- use_module gcc.
-:- import_module parse_tree.
-:- import_module hlds.
+
+:- import_module backend_libs.
:- import_module check_hlds.
+:- import_module hlds.
:- import_module libs.
-:- import_module backend_libs.
:- import_module ll_backend. % XXX
+:- import_module parse_tree.
% XXX some of these imports might be unused
-:- import_module ml_backend__ml_util.
-:- import_module ml_backend__mlds_to_c. % to handle C foreign_code
+:- import_module backend_libs__builtin_ops.
+:- import_module backend_libs__code_model.
+:- import_module backend_libs__pseudo_type_info.
+:- import_module backend_libs__rtti. % for rtti__addr_to_string.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module hlds__hlds_pred. % for proc_id_to_int and invalid_pred_id
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
:- import_module ll_backend__llds_out. % XXX needed for llds_out__name_mangle,
% llds_out__sym_name_mangle,
% llds_out__make_base_typeclass_info_name,
-:- import_module backend_libs__rtti. % for rtti__addr_to_string.
-:- import_module ml_backend__ml_code_util. % for ml_gen_public_field_decl_flags, which is
- % used by the code that handles derived classes
-:- import_module hlds__hlds_pred. % for proc_id_to_int and invalid_pred_id
-:- import_module libs__globals, libs__options, hlds__passes_aux.
-:- import_module backend_libs__builtin_ops, parse_tree__modules.
-:- import_module parse_tree__prog_data, parse_tree__prog_out.
-:- import_module parse_tree__prog_util, check_hlds__type_util.
-:- import_module hlds__error_util.
-:- import_module backend_libs__pseudo_type_info, backend_libs__code_model.
+:- import_module ml_backend__ml_code_util.% for ml_gen_public_field_decl_flags,
+ % which is used by the code that handles
+ % derived classes
+:- import_module ml_backend__ml_util.
+:- import_module ml_backend__mlds_to_c. % to handle C foreign_code
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
:- import_module bool, int, string, library, list, map.
:- import_module assoc_list, term, std_util, require.
Index: compiler/mlds_to_il.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mlds_to_il.m,v
retrieving revision 1.127
diff -u -b -r1.127 mlds_to_il.m
--- compiler/mlds_to_il.m 5 Mar 2003 15:55:20 -0000 1.127
+++ compiler/mlds_to_il.m 14 Mar 2003 09:44:30 -0000
@@ -58,10 +58,13 @@
:- module ml_backend__mlds_to_il.
:- interface.
-:- import_module ml_backend__mlds, ml_backend__ilasm, ml_backend__ilds.
-:- import_module io, list, bool, std_util, set.
:- import_module hlds__hlds_pred. % for `pred_proc_id'.
:- import_module libs__globals. % for `foreign_language'.
+:- import_module ml_backend__ilasm.
+:- import_module ml_backend__ilds.
+:- import_module ml_backend__mlds.
+
+:- import_module io, list, bool, std_util, set.
%-----------------------------------------------------------------------------%
@@ -74,7 +77,6 @@
io__state, io__state).
:- mode generate_il(in, out, out, di, uo) is det.
-
%-----------------------------------------------------------------------------%
%
@@ -132,20 +134,29 @@
:- implementation.
-:- import_module libs__globals, libs__options, hlds__passes_aux.
-:- import_module backend_libs__builtin_ops, backend_libs__c_util.
-:- import_module parse_tree__modules, libs__tree.
-:- import_module parse_tree__prog_data, parse_tree__prog_out.
-:- import_module parse_tree__prog_util, ll_backend__llds_out.
-:- import_module backend_libs__pseudo_type_info, backend_libs__rtti.
-:- import_module check_hlds__type_util, backend_libs__code_model.
+:- import_module backend_libs__builtin_ops.
+:- import_module backend_libs__c_util.
+:- import_module backend_libs__code_model.
:- import_module backend_libs__foreign.
-
-:- import_module ml_backend__il_peephole.
-:- import_module ml_backend__ml_util, ml_backend__ml_code_util.
+:- import_module backend_libs__foreign.
+:- import_module backend_libs__pseudo_type_info.
+:- import_module backend_libs__rtti.
+:- import_module check_hlds__type_util.
:- import_module hlds__error_util.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__tree.
+:- import_module ll_backend__llds_out.
+:- import_module ml_backend__il_peephole.
+:- import_module ml_backend__ml_code_util.
:- import_module ml_backend__ml_type_gen.
-:- import_module backend_libs__foreign.
+:- import_module ml_backend__ml_util.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
+
:- use_module ll_backend__llds. /* for user_foreign_code */
:- import_module bool, int, map, string, set, list, assoc_list, term.
Index: compiler/mlds_to_ilasm.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mlds_to_ilasm.m,v
retrieving revision 1.20
diff -u -b -r1.20 mlds_to_ilasm.m
--- compiler/mlds_to_ilasm.m 11 Feb 2003 02:14:27 -0000 1.20
+++ compiler/mlds_to_ilasm.m 14 Mar 2003 09:44:50 -0000
@@ -16,6 +16,7 @@
:- interface.
:- import_module ml_backend__mlds.
+
:- import_module io.
% Convert the MLDS to IL and write it to a file.
@@ -28,17 +29,26 @@
:- implementation.
-:- import_module libs__globals, libs__options, hlds__passes_aux.
-:- import_module backend_libs__builtin_ops, backend_libs__c_util.
-:- import_module parse_tree__modules, libs__tree.
-:- import_module hlds__hlds_pred. % for `pred_proc_id'.
-:- import_module parse_tree__prog_data, parse_tree__prog_out.
-:- import_module backend_libs__rtti, check_hlds__type_util, hlds__error_util.
+:- import_module backend_libs__builtin_ops.
+:- import_module backend_libs__c_util.
:- import_module backend_libs__foreign.
-
-:- import_module ml_backend__ilds, ml_backend__ilasm, ml_backend__il_peephole.
-:- import_module ml_backend__ml_util, ml_backend__ml_code_util.
+:- import_module backend_libs__rtti.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module hlds__hlds_pred. % for `pred_proc_id'.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__tree.
+:- import_module ml_backend__il_peephole.
+:- import_module ml_backend__ilasm.
+:- import_module ml_backend__ilds.
+:- import_module ml_backend__ml_code_util.
+:- import_module ml_backend__ml_util.
:- import_module ml_backend__mlds_to_managed.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
:- import_module bool, int, map, string, set, list, assoc_list, term, std_util.
:- import_module library, require, counter.
Index: compiler/mlds_to_java.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mlds_to_java.m,v
retrieving revision 1.36
diff -u -b -r1.36 mlds_to_java.m
--- compiler/mlds_to_java.m 11 Feb 2003 02:14:27 -0000 1.36
+++ compiler/mlds_to_java.m 14 Mar 2003 09:45:37 -0000
@@ -49,6 +49,7 @@
:- interface.
:- import_module ml_backend__mlds.
+
:- import_module io.
:- pred mlds_to_java__output_mlds(mlds, io__state, io__state).
@@ -59,27 +60,31 @@
:- implementation.
-:- import_module ml_backend__ml_util.
-:- import_module ml_backend__java_util.
-:- import_module backend_libs__c_util.
% XXX needed for c_util__output_quoted_string,
% c_util__output_quoted_multi_string, and
% c_util__make_float_literal.
+:- import_module backend_libs__builtin_ops.
+:- import_module backend_libs__c_util.
+:- import_module backend_libs__export. % for export__type_to_type_string
+:- import_module backend_libs__foreign.
+:- import_module backend_libs__rtti. % for rtti__addr_to_string.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module hlds__hlds_pred. % for pred_proc_id.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
:- import_module ll_backend__llds_out. % XXX needed for llds_out__name_mangle,
% llds_out__sym_name_mangle,
% llds_out__make_base_typeclass_info_name,
-:- import_module backend_libs__rtti. % for rtti__addr_to_string.
-:- import_module ml_backend__rtti_to_mlds. % for mlds_rtti_type_name.
-:- import_module hlds__hlds_pred. % for pred_proc_id.
-:- import_module parse_tree__modules. % for mercury_std_library_name.
+:- import_module ml_backend__java_util.
:- import_module ml_backend__ml_code_util. % for ml_gen_local_var_decl_flags.
:- import_module ml_backend__ml_type_gen. % for ml_gen_type_name
-:- import_module backend_libs__export. % for export__type_to_type_string
-:- import_module libs__globals, libs__options, hlds__passes_aux.
-:- import_module backend_libs__builtin_ops.
-:- import_module parse_tree__prog_data, parse_tree__prog_out.
-:- import_module check_hlds__type_util, hlds__error_util.
-:- import_module backend_libs__foreign.
+:- import_module ml_backend__ml_util.
+:- import_module ml_backend__rtti_to_mlds. % for mlds_rtti_type_name.
+:- import_module parse_tree__modules. % for mercury_std_library_name.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
:- import_module bool, int, string, library, list, map, set.
:- import_module assoc_list, term, std_util, require.
Index: compiler/mlds_to_managed.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mlds_to_managed.m,v
retrieving revision 1.7
diff -u -b -r1.7 mlds_to_managed.m
--- compiler/mlds_to_managed.m 3 Mar 2003 14:33:28 -0000 1.7
+++ compiler/mlds_to_managed.m 14 Mar 2003 09:46:08 -0000
@@ -13,8 +13,9 @@
:- module ml_backend__mlds_to_managed.
:- interface.
-:- import_module ml_backend__mlds.
:- import_module libs__globals.
+:- import_module ml_backend__mlds.
+
:- import_module io.
:- inst managed_lang == bound(csharp; managed_cplusplus).
@@ -38,21 +39,29 @@
:- implementation.
-:- import_module libs__globals, libs__options, hlds__passes_aux.
-:- import_module backend_libs__builtin_ops, backend_libs__c_util.
-:- import_module parse_tree__modules, libs__tree.
+:- import_module backend_libs__builtin_ops.
+:- import_module backend_libs__c_util.
+:- import_module backend_libs__foreign.
+:- import_module backend_libs__rtti.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
:- import_module hlds__hlds_pred. % for `pred_proc_id'.
-:- import_module parse_tree__prog_data, parse_tree__prog_out.
-:- import_module backend_libs__foreign, backend_libs__rtti.
-:- import_module check_hlds__type_util, hlds__error_util.
-
-:- import_module ml_backend__ilds, ml_backend__ilasm, ml_backend__il_peephole.
-:- import_module ml_backend__ml_util, ml_backend__ml_code_util.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__tree.
+:- import_module ml_backend__il_peephole.
+:- import_module ml_backend__ilasm.
+:- import_module ml_backend__ilds.
+:- import_module ml_backend__ml_code_util.
+:- import_module ml_backend__ml_util.
+:- import_module ml_backend__mlds_to_il.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
:- import_module bool, int, map, string, list, assoc_list, term, std_util.
:- import_module library, require, counter.
-
-:- import_module ml_backend__mlds_to_il.
output_managed_code(Lang, MLDS) -->
{ MLDS = mlds(ModuleName, _ForeignCode, _Imports, _Defns) },
Index: compiler/mmc_analysis.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mmc_analysis.m,v
retrieving revision 1.1
diff -u -b -r1.1 mmc_analysis.m
--- compiler/mmc_analysis.m 2 Jan 2003 07:35:00 -0000 1.1
+++ compiler/mmc_analysis.m 14 Mar 2003 09:46:22 -0000
@@ -13,9 +13,9 @@
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_pred.
:- import_module analysis.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
:- type mmc ---> mmc.
@@ -29,9 +29,10 @@
:- implementation.
-:- import_module parse_tree__prog_out, parse_tree__prog_util.
-:- import_module parse_tree__modules.
:- import_module hlds__hlds_out.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
:- import_module transform_hlds__unused_args.
:- import_module bool, std_util, string.
Index: compiler/mode_debug.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mode_debug.m,v
retrieving revision 1.14
diff -u -b -r1.14 mode_debug.m
--- compiler/mode_debug.m 20 Mar 2002 12:36:53 -0000 1.14
+++ compiler/mode_debug.m 14 Mar 2003 09:46:41 -0000
@@ -33,12 +33,20 @@
%-----------------------------------------------------------------------------%
:- implementation.
+
+:- import_module check_hlds__modes.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__instmap.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_data.
+
:- import_module std_util, list, assoc_list, io, bool, map.
:- import_module term, varset.
-:- import_module check_hlds__modes, libs__globals, libs__options.
-:- import_module parse_tree__mercury_to_mercury, hlds__passes_aux.
-:- import_module hlds__hlds_goal, hlds__hlds_module, hlds__instmap.
-:- import_module parse_tree__prog_data, (parse_tree__inst).
%-----------------------------------------------------------------------------%
Index: compiler/mode_errors.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mode_errors.m,v
retrieving revision 1.73
diff -u -b -r1.73 mode_errors.m
--- compiler/mode_errors.m 12 Aug 2002 02:37:11 -0000 1.73
+++ compiler/mode_errors.m 14 Mar 2003 09:47:00 -0000
@@ -17,10 +17,13 @@
:- interface.
-:- import_module hlds__hlds_data, hlds__hlds_pred, hlds__hlds_module.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__hlds_module.
:- import_module hlds__hlds_goal.
-:- import_module parse_tree__prog_data, check_hlds__mode_info.
-:- import_module (parse_tree__inst).
+:- import_module parse_tree__prog_data.
+:- import_module check_hlds__mode_info.
+:- import_module parse_tree__inst.
:- import_module bool, set, assoc_list, list, io.
@@ -188,10 +191,13 @@
:- implementation.
+:- import_module check_hlds__mode_info.
+:- import_module check_hlds__mode_util.
:- import_module hlds__hlds_out.
-:- import_module check_hlds__mode_info, check_hlds__mode_util.
-:- import_module parse_tree__prog_out, parse_tree__mercury_to_mercury.
-:- import_module libs__options, libs__globals.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_out.
:- import_module int, map, term_io, varset, term.
:- import_module std_util, require.
Index: compiler/mode_info.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mode_info.m,v
retrieving revision 1.61
diff -u -b -r1.61 mode_info.m
--- compiler/mode_info.m 20 Mar 2002 12:36:53 -0000 1.61
+++ compiler/mode_info.m 14 Mar 2003 09:47:19 -0000
@@ -16,10 +16,16 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_goal.
-:- import_module hlds__hlds_data, hlds__instmap.
-:- import_module parse_tree__prog_data, check_hlds__mode_errors.
-:- import_module check_hlds__delay_info, (parse_tree__inst).
+:- import_module check_hlds__delay_info.
+:- import_module check_hlds__mode_errors.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+
:- import_module map, list, set, bool, assoc_list, std_util, io.
:- interface.
@@ -341,8 +347,10 @@
:- implementation.
-:- import_module check_hlds__delay_info, check_hlds__mode_errors.
+:- import_module check_hlds__delay_info.
+:- import_module check_hlds__mode_errors.
:- import_module check_hlds__mode_util.
+
:- import_module term, varset.
:- import_module require, std_util, queue.
Index: compiler/mode_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mode_util.m,v
retrieving revision 1.148
diff -u -b -r1.148 mode_util.m
--- compiler/mode_util.m 27 Jan 2003 09:20:48 -0000 1.148
+++ compiler/mode_util.m 14 Mar 2003 09:47:55 -0000
@@ -14,9 +14,14 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_goal.
-:- import_module hlds__hlds_data, parse_tree__prog_data.
-:- import_module (parse_tree__inst), hlds__instmap.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+
:- import_module bool, list.
% mode_get_insts returns the initial instantiatedness and
@@ -227,11 +232,14 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module require, int, map, set, std_util, assoc_list, varset.
-:- import_module parse_tree__prog_util, parse_tree__prog_io.
-:- import_module check_hlds__type_util.
-:- import_module check_hlds__inst_match, check_hlds__inst_util.
+
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__inst_util.
:- import_module check_hlds__mode_info.
+:- import_module check_hlds__type_util.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_util.
+
:- import_module require, int, map, set, term, std_util, assoc_list, varset.
%-----------------------------------------------------------------------------%
Index: compiler/modecheck_call.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/modecheck_call.m,v
retrieving revision 1.41
diff -u -b -r1.41 modecheck_call.m
--- compiler/modecheck_call.m 27 Jan 2003 09:20:49 -0000 1.41
+++ compiler/modecheck_call.m 14 Mar 2003 09:48:19 -0000
@@ -21,9 +21,13 @@
:- module check_hlds__modecheck_call.
:- interface.
-:- import_module hlds__hlds_goal, hlds__hlds_pred, hlds__hlds_module.
-:- import_module parse_tree__prog_data, check_hlds__modes.
:- import_module check_hlds__mode_info.
+:- import_module check_hlds__modes.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
+
:- import_module list, std_util.
:- pred modecheck_call_pred(pred_id, proc_id, list(prog_var),
@@ -70,14 +74,23 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module hlds__hlds_data, hlds__instmap, parse_tree__prog_data.
-:- import_module (parse_tree__inst), check_hlds__inst_util.
-:- import_module check_hlds__type_util.
-:- import_module check_hlds__mode_info, check_hlds__mode_debug.
-:- import_module check_hlds__modes, check_hlds__mode_util.
+
+:- import_module check_hlds__clause_to_proc.
+:- import_module check_hlds__det_report.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__inst_util.
+:- import_module check_hlds__mode_debug.
:- import_module check_hlds__mode_errors.
-:- import_module check_hlds__clause_to_proc, check_hlds__inst_match.
-:- import_module check_hlds__det_report, check_hlds__unify_proc.
+:- import_module check_hlds__mode_info.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__modes.
+:- import_module check_hlds__type_util.
+:- import_module check_hlds__unify_proc.
+:- import_module hlds__hlds_data.
+:- import_module hlds__instmap.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+
:- import_module int, map, bool, set, require, term, varset.
modecheck_higher_order_call(PredOrFunc, PredVar, Args0, Modes, Det,
Index: compiler/modecheck_unify.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/modecheck_unify.m,v
retrieving revision 1.54
diff -u -b -r1.54 modecheck_unify.m
--- compiler/modecheck_unify.m 28 Feb 2003 06:40:42 -0000 1.54
+++ compiler/modecheck_unify.m 14 Mar 2003 09:50:53 -0000
@@ -20,7 +20,9 @@
:- module check_hlds__modecheck_unify.
:- interface.
-:- import_module hlds__hlds_goal, parse_tree__prog_data, check_hlds__mode_info.
+:- import_module check_hlds__mode_info.
+:- import_module hlds__hlds_goal.
+:- import_module parse_tree__prog_data.
% Modecheck a unification
:- pred modecheck_unification(prog_var, unify_rhs, unification, unify_context,
@@ -40,19 +42,30 @@
:- implementation.
-:- import_module ll_backend__llds, parse_tree__prog_util.
-:- import_module check_hlds__type_util, parse_tree__module_qual, hlds__instmap.
-:- import_module hlds__hlds_module, hlds__hlds_goal, hlds__hlds_pred.
-:- import_module hlds__hlds_data, hlds__hlds_out.
-:- import_module check_hlds__mode_debug, check_hlds__mode_util.
-:- import_module check_hlds__mode_info, check_hlds__modes.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__inst_util.
+:- import_module check_hlds__mode_debug.
:- import_module check_hlds__mode_errors.
-:- import_module check_hlds__inst_match, check_hlds__inst_util.
+:- import_module check_hlds__mode_info.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__modecheck_call.
+:- import_module check_hlds__modes.
+:- import_module check_hlds__polymorphism.
+:- import_module check_hlds__type_util.
+:- import_module check_hlds__typecheck.
:- import_module check_hlds__unify_proc.
:- import_module check_hlds__unique_modes.
-:- import_module check_hlds__typecheck, check_hlds__modecheck_call.
-:- import_module (parse_tree__inst), hlds__quantification, hlds__make_hlds.
-:- import_module check_hlds__polymorphism.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_out.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module hlds__make_hlds.
+:- import_module hlds__quantification.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__module_qual.
+:- import_module parse_tree__prog_util.
:- import_module bool, list, map, std_util, int, set, require.
:- import_module string, assoc_list.
Index: compiler/modes.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/modes.m,v
retrieving revision 1.265
diff -u -b -r1.265 modes.m
--- compiler/modes.m 28 Feb 2003 06:40:42 -0000 1.265
+++ compiler/modes.m 14 Mar 2003 09:52:25 -0000
@@ -131,8 +131,13 @@
:- interface.
-:- import_module parse_tree__prog_data, hlds__hlds_goal, hlds__hlds_module.
-:- import_module hlds__hlds_pred, (parse_tree__inst), hlds__instmap.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+
:- import_module bool, list, io.
% modecheck(HLDS0, HLDS, UnsafeToContinue):
@@ -323,22 +328,34 @@
:- implementation.
-:- import_module hlds__make_hlds, hlds__hlds_data, check_hlds__unique_modes.
+:- import_module check_hlds__clause_to_proc.
+:- import_module check_hlds__delay_info.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__inst_util.
:- import_module check_hlds__mode_debug.
-:- import_module check_hlds__mode_info, check_hlds__delay_info.
-:- import_module check_hlds__mode_errors, check_hlds__inst_match.
+:- import_module check_hlds__mode_errors.
+:- import_module check_hlds__mode_info.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__modecheck_call.
+:- import_module check_hlds__modecheck_unify.
+:- import_module check_hlds__purity.
+:- import_module check_hlds__type_util.
+:- import_module check_hlds__typecheck.
+:- import_module check_hlds__unify_proc.
+:- import_module check_hlds__unique_modes.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_out.
:- import_module hlds__instmap.
-:- import_module check_hlds__type_util, check_hlds__mode_util.
-:- import_module ll_backend__code_util, check_hlds__unify_proc.
+:- import_module hlds__make_hlds.
+:- import_module hlds__passes_aux.
:- import_module hlds__special_pred.
-:- import_module libs__globals, libs__options, parse_tree__mercury_to_mercury.
-:- import_module hlds__hlds_out, int, set.
-:- import_module hlds__passes_aux, check_hlds__typecheck.
-:- import_module parse_tree__module_qual, check_hlds__clause_to_proc.
-:- import_module check_hlds__modecheck_unify, check_hlds__modecheck_call.
-:- import_module check_hlds__inst_util, check_hlds__purity.
-:- import_module parse_tree__prog_out, term, varset.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__module_qual.
+:- import_module parse_tree__prog_out.
+:- import_module int, set, term, varset.
:- import_module list, map, string, require, std_util.
:- import_module assoc_list.
Index: compiler/module_qual.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/module_qual.m,v
retrieving revision 1.84
diff -u -b -r1.84 module_qual.m
--- compiler/module_qual.m 12 Feb 2003 22:58:10 -0000 1.84
+++ compiler/module_qual.m 14 Mar 2003 09:52:46 -0000
@@ -19,7 +19,9 @@
%
:- interface.
-:- import_module parse_tree__prog_data, recompilation.
+:- import_module parse_tree__prog_data.
+:- import_module recompilation.
+
:- import_module bool, list, std_util, io.
% module_qualify_items(Items0, Items, ModuleName, ReportUndefErrors,
@@ -111,12 +113,18 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module check_hlds__type_util, parse_tree__prog_io.
-:- import_module parse_tree__prog_out, hlds__hlds_out.
-:- import_module parse_tree__prog_util, parse_tree__mercury_to_mercury.
-:- import_module parse_tree__modules, libs__globals, libs__options.
-:- import_module (parse_tree__inst), hlds__instmap.
+:- import_module check_hlds__type_util.
:- import_module hlds__hlds_data. % for cons_id.
+:- import_module hlds__hlds_out.
+:- import_module hlds__instmap.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
:- import_module int, map, require, set, string, term, varset.
:- import_module assoc_list.
Index: compiler/modules.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/modules.m,v
retrieving revision 1.267
diff -u -b -r1.267 modules.m
--- compiler/modules.m 19 Feb 2003 05:54:37 -0000 1.267
+++ compiler/modules.m 14 Mar 2003 09:53:20 -0000
@@ -39,8 +39,12 @@
:- interface.
-:- import_module backend_libs__foreign, parse_tree__prog_data.
-:- import_module parse_tree__prog_io, libs__globals, libs__timestamp.
+:- import_module backend_libs__foreign.
+:- import_module libs__globals.
+:- import_module libs__timestamp.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_io.
+
:- import_module std_util, bool, list, map, set, io.
%-----------------------------------------------------------------------------%
@@ -738,13 +742,20 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module ll_backend__llds_out, hlds__passes_aux, parse_tree__prog_out.
-:- import_module parse_tree__prog_util, parse_tree__mercury_to_mercury.
-:- import_module parse_tree__prog_io_util, libs__options, libs__handle_options.
+
+:- import_module backend_libs__foreign.
+:- import_module hlds__passes_aux.
+:- import_module libs__handle_options.
+:- import_module libs__options.
+:- import_module ll_backend__llds_out.
+:- import_module make. % XXX undesirable dependency
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__module_qual.
+:- import_module parse_tree__prog_io_util.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
:- import_module parse_tree__source_file_map.
-:- import_module parse_tree__module_qual, backend_libs__foreign.
:- import_module recompilation__version.
-:- import_module make. % XXX undesirable dependency
:- import_module string, map, term, varset, dir, library.
:- import_module assoc_list, relation, char, require.
Index: compiler/opt_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/opt_util.m,v
retrieving revision 1.116
diff -u -b -r1.116 opt_util.m
--- compiler/opt_util.m 14 Mar 2003 08:10:09 -0000 1.116
+++ compiler/opt_util.m 14 Mar 2003 09:53:33 -0000
@@ -13,7 +13,9 @@
:- module ll_backend__opt_util.
:- interface.
+
:- import_module ll_backend__llds.
+
:- import_module bool, map, list, std_util.
:- type instrmap == map(label, instruction).
Index: compiler/optimize.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/optimize.m,v
retrieving revision 1.34
diff -u -b -r1.34 optimize.m
--- compiler/optimize.m 14 Mar 2003 08:10:09 -0000 1.34
+++ compiler/optimize.m 14 Mar 2003 09:53:38 -0000
@@ -15,6 +15,7 @@
:- interface.
:- import_module ll_backend__llds.
+
:- import_module io, list.
:- pred optimize_main(list(c_procedure)::in, global_data::in,
Index: compiler/options.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/options.m,v
retrieving revision 1.408
diff -u -b -r1.408 options.m
--- compiler/options.m 5 Mar 2003 15:55:20 -0000 1.408
+++ compiler/options.m 14 Mar 2003 09:54:38 -0000
@@ -18,6 +18,7 @@
:- module libs__options.
:- interface.
+
:- import_module char, io, getopt.
:- pred short_option(char::in, option::out) is semidet.
@@ -660,9 +661,10 @@
:- implementation.
+:- import_module libs__handle_options.
+
:- import_module string, bool, int, map, std_util, assoc_list, require, list.
:- import_module dir.
-:- import_module libs__handle_options.
:- type option_category
---> warning_option
Index: compiler/options_file.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/options_file.m,v
retrieving revision 1.16
diff -u -b -r1.16 options_file.m
--- compiler/options_file.m 1 Mar 2003 06:34:51 -0000 1.16
+++ compiler/options_file.m 14 Mar 2003 09:54:51 -0000
@@ -14,6 +14,7 @@
:- interface.
:- import_module parse_tree__prog_data.
+
:- import_module list, io, std_util.
:- type options_variables.
@@ -50,8 +51,11 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module parse_tree__prog_io, parse_tree__prog_out.
-:- import_module hlds__error_util, libs__globals, libs__options.
+:- import_module hlds__error_util.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_out.
:- import_module assoc_list, bool, char, dir, exception, map.
:- import_module require, string, term.
Index: compiler/par_conj_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/par_conj_gen.m,v
retrieving revision 1.10
diff -u -b -r1.10 par_conj_gen.m
--- compiler/par_conj_gen.m 28 Mar 2002 03:43:30 -0000 1.10
+++ compiler/par_conj_gen.m 14 Mar 2003 09:55:15 -0000
@@ -96,8 +96,11 @@
:- interface.
-:- import_module hlds__hlds_goal, backend_libs__code_model, ll_backend__llds.
+:- import_module backend_libs__code_model.
+:- import_module hlds__hlds_goal.
:- import_module ll_backend__code_info.
+:- import_module ll_backend__llds.
+
:- import_module list.
:- pred par_conj_gen__generate_par_conj(list(hlds_goal)::in,
@@ -108,12 +111,19 @@
:- implementation.
-:- import_module parse_tree__prog_data, parse_tree__inst.
-:- import_module hlds__hlds_module, hlds__hlds_data, hlds__instmap.
:- import_module check_hlds__mode_util.
-:- import_module ll_backend__code_gen, ll_backend__code_util.
-:- import_module ll_backend__code_info, ll_backend__continuation_info.
-:- import_module libs__options, libs__globals, libs__tree.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__instmap.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__tree.
+:- import_module ll_backend__code_gen.
+:- import_module ll_backend__code_info.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__continuation_info.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
:- import_module bool, int, list, set, map, std_util, require.
Index: compiler/parse_tree.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/parse_tree.m,v
retrieving revision 1.2
diff -u -b -r1.2 parse_tree.m
--- compiler/parse_tree.m 15 Apr 2002 05:04:13 -0000 1.2
+++ compiler/parse_tree.m 14 Mar 2003 09:56:11 -0000
@@ -13,21 +13,27 @@
:- module parse_tree.
:- interface.
+
:- import_module libs.
:- import_module hlds. % XXX for hlds_data__cons_id
:- import_module backend_libs. % XXX for `foreign'
% The parse tree data type itself.
-:- include_module prog_data, (inst).
+:- include_module prog_data.
+:- include_module (inst).
% XXX inst uses hlds_data__cons_id
% The parser.
:- include_module prog_io.
- :- include_module prog_io_goal, prog_io_dcg, prog_io_pragma.
- :- include_module prog_io_typeclass, prog_io_util.
+ :- include_module prog_io_dcg.
+ :- include_module prog_io_goal.
+ :- include_module prog_io_pragma.
+ :- include_module prog_io_typeclass.
+ :- include_module prog_io_util.
% Pretty-printers.
-:- include_module prog_out, mercury_to_mercury.
+:- include_module mercury_to_mercury.
+:- include_module prog_out.
% Utility routines.
:- include_module prog_util.
@@ -35,12 +41,15 @@
% Transformations that act on the parse tree,
% and stuff relating to the module system.
:- include_module equiv_type.
-:- include_module modules, module_qual, source_file_map.
+:- include_module modules.
+:- include_module module_qual.
+:- include_module source_file_map.
% (Note that intermod and trans_opt also contain routines that
% act on the parse tree, but those modules are considered part
% of the HLDS transformations package.)
-% :- include_module intermod, trans_opt.
+% :- include_module intermod.
+% :- include_module trans_opt.
% :- implementation.
@@ -52,13 +61,13 @@
:- implementation.
:- import_module check_hlds. % XXX for type_util.m
-:- import_module transform_hlds. % XXX for write_pragma_termination_info
- % in termination.m, which is used by
- % mercury_to_mercury.m
:- import_module ll_backend. % XXX for llds_out.m, which is used
% by modules__append_to_init_list,
% which creates the LLDS and RL
% initialization code.
+:- import_module transform_hlds. % XXX for write_pragma_termination_info
+ % in termination.m, which is used by
+ % mercury_to_mercury.m
:- end_module parse_tree.
%-----------------------------------------------------------------------------%
Index: compiler/passes_aux.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/passes_aux.m,v
retrieving revision 1.53
diff -u -b -r1.53 passes_aux.m
--- compiler/passes_aux.m 19 Feb 2003 07:42:42 -0000 1.53
+++ compiler/passes_aux.m 14 Mar 2003 09:56:27 -0000
@@ -13,7 +13,10 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, parse_tree__prog_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
+
:- import_module io, std_util, list, bool.
%-----------------------------------------------------------------------------%
@@ -242,9 +245,13 @@
:- implementation.
-:- import_module libs__options, libs__globals, hlds__hlds_out.
-:- import_module parse_tree__prog_out, check_hlds__mode_util.
-:- import_module parse_tree__mercury_to_mercury, libs__process_util.
+:- import_module check_hlds__mode_util.
+:- import_module hlds__hlds_out.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__process_util.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_out.
:- import_module int, string, map, require, varset.
Index: compiler/pd_cost.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/pd_cost.m,v
retrieving revision 1.14
diff -u -b -r1.14 pd_cost.m
--- compiler/pd_cost.m 28 Mar 2002 03:43:30 -0000 1.14
+++ compiler/pd_cost.m 14 Mar 2003 09:56:33 -0000
@@ -35,7 +35,9 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module hlds__hlds_data, parse_tree__prog_data.
+:- import_module hlds__hlds_data.
+:- import_module parse_tree__prog_data.
+
:- import_module int, list, set, std_util, require.
%-----------------------------------------------------------------------------%
Index: compiler/pd_debug.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/pd_debug.m,v
retrieving revision 1.6
diff -u -b -r1.6 pd_debug.m
--- compiler/pd_debug.m 20 Mar 2002 12:37:06 -0000 1.6
+++ compiler/pd_debug.m 14 Mar 2003 09:56:52 -0000
@@ -12,8 +12,11 @@
:- interface.
-:- import_module transform_hlds__pd_info, hlds__hlds_goal, hlds__hlds_pred.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_pred.
:- import_module parse_tree__prog_data.
+:- import_module transform_hlds__pd_info.
+
:- import_module list, string.
:- pred pd_debug__do_io(pred(io__state, io__state)::pred(di, uo) is det,
@@ -47,10 +50,16 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module libs__globals, hlds__hlds_module, hlds__hlds_out.
-:- import_module hlds__instmap, libs__options.
-:- import_module hlds__instmap, parse_tree__prog_out, hlds__goal_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_out.
+:- import_module hlds__instmap.
+:- import_module hlds__instmap.
+:- import_module libs__globals.
+:- import_module libs__options.
:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_out.
+
:- import_module bool, io, set, std_util.
pd_debug__do_io(Pred) -->
Index: compiler/pd_info.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/pd_info.m,v
retrieving revision 1.9
diff -u -b -r1.9 pd_info.m
--- compiler/pd_info.m 20 Mar 2002 12:37:06 -0000 1.9
+++ compiler/pd_info.m 14 Mar 2003 09:57:12 -0000
@@ -13,9 +13,15 @@
:- interface.
-:- import_module transform_hlds__pd_term, hlds__hlds_module, hlds__hlds_pred.
-:- import_module libs__options, hlds__hlds_data, hlds__instmap.
-:- import_module hlds__hlds_goal, parse_tree__prog_data.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module libs__options.
+:- import_module parse_tree__prog_data.
+:- import_module transform_hlds__pd_term.
+
:- import_module bool, map, list, io, set, std_util, getopt.
:- type pd_info
@@ -159,11 +165,17 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module hlds__hlds_pred, parse_tree__prog_data.
-:- import_module transform_hlds__pd_debug, transform_hlds__pd_util.
-:- import_module check_hlds__det_util, libs__globals.
-:- import_module check_hlds__inst_match, hlds__hlds_goal.
-:- import_module parse_tree__prog_util, term.
+:- import_module check_hlds__det_util.
+:- import_module check_hlds__inst_match.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_pred.
+:- import_module libs__globals.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_util.
+:- import_module transform_hlds__pd_debug.
+:- import_module transform_hlds__pd_util.
+
+:- import_module term.
:- import_module assoc_list, bool, int, require, string.
pd_info_init(ModuleInfo, ProcArgInfos, IO, PdInfo) :-
Index: compiler/pd_term.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/pd_term.m,v
retrieving revision 1.4
diff -u -b -r1.4 pd_term.m
--- compiler/pd_term.m 20 Mar 2002 12:37:06 -0000 1.4
+++ compiler/pd_term.m 14 Mar 2003 09:57:32 -0000
@@ -35,8 +35,12 @@
:- interface.
-:- import_module hlds__hlds_goal, hlds__hlds_module, hlds__hlds_pred.
-:- import_module hlds__instmap, transform_hlds__pd_info.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module transform_hlds__pd_info.
+
:- import_module list, std_util.
% pd_term__global_check(Module, CallGoal1, BetweenGoals, CallGoal2,
@@ -87,8 +91,12 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module hlds__hlds_pred, (parse_tree__inst), check_hlds__mode_util.
-:- import_module parse_tree__prog_data, transform_hlds__pd_util.
+:- import_module check_hlds__mode_util.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+:- import_module transform_hlds__pd_util.
+
:- import_module assoc_list, bool, int, map, require, set.
:- type global_term_info
Index: compiler/pd_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/pd_util.m,v
retrieving revision 1.22
diff -u -b -r1.22 pd_util.m
--- compiler/pd_util.m 6 Feb 2003 00:36:38 -0000 1.22
+++ compiler/pd_util.m 14 Mar 2003 09:57:55 -0000
@@ -13,10 +13,15 @@
:- interface.
-:- import_module transform_hlds__pd_info, hlds__hlds_goal, hlds__hlds_module.
-:- import_module hlds__hlds_pred, check_hlds__mode_errors.
-:- import_module parse_tree__prog_data, check_hlds__simplify.
-:- import_module (parse_tree__inst).
+:- import_module check_hlds__mode_errors.
+:- import_module check_hlds__simplify.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+:- import_module transform_hlds__pd_info.
+
:- import_module bool, list, map, set, std_util.
% Pick out the pred_proc_ids of the calls in a list of atomic goals.
@@ -140,17 +145,28 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module parse_tree__inst.
-:- import_module hlds__goal_util, hlds__hlds_data, hlds__instmap.
-:- import_module hlds__quantification, hlds__goal_form.
-:- import_module check_hlds__purity, check_hlds__type_util.
-:- import_module check_hlds__mode_info, check_hlds__unique_modes.
-:- import_module check_hlds__mode_util, check_hlds__inst_util.
-:- import_module check_hlds__inst_match, check_hlds__det_report.
-:- import_module check_hlds__det_util, check_hlds__det_analysis.
-:- import_module transform_hlds__pd_cost, transform_hlds__pd_debug.
-:- import_module transform_hlds__constraint, transform_hlds__unused_args.
+:- import_module check_hlds__det_analysis.
+:- import_module check_hlds__det_report.
+:- import_module check_hlds__det_util.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__inst_util.
+:- import_module check_hlds__mode_info.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__purity.
+:- import_module check_hlds__type_util.
+:- import_module check_hlds__unique_modes.
+:- import_module hlds__goal_form.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__instmap.
+:- import_module hlds__quantification.
:- import_module libs__options.
+:- import_module parse_tree__inst.
+:- import_module transform_hlds__constraint.
+:- import_module transform_hlds__pd_cost.
+:- import_module transform_hlds__pd_debug.
+:- import_module transform_hlds__unused_args.
+
:- import_module assoc_list, int, require, set, term.
pd_util__goal_get_calls(Goal0, CalledPreds) :-
Index: compiler/peephole.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/peephole.m,v
retrieving revision 1.78
diff -u -b -r1.78 peephole.m
--- compiler/peephole.m 20 Mar 2002 12:37:06 -0000 1.78
+++ compiler/peephole.m 14 Mar 2003 09:58:06 -0000
@@ -14,8 +14,10 @@
:- interface.
+:- import_module ll_backend__llds.
+:- import_module libs__globals.
+
:- import_module bool, list.
-:- import_module ll_backend__llds, libs__globals.
% Peephole optimize a list of instructions.
@@ -25,8 +27,11 @@
:- implementation.
-:- import_module backend_libs__builtin_ops, ll_backend__code_util.
-:- import_module ll_backend__opt_util, ll_backend__opt_debug.
+:- import_module backend_libs__builtin_ops.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__opt_debug.
+:- import_module ll_backend__opt_util.
+
:- import_module int, map, string, std_util.
% Patterns that can be switched off.
Index: compiler/polymorphism.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/polymorphism.m,v
retrieving revision 1.233
diff -u -b -r1.233 polymorphism.m
--- compiler/polymorphism.m 28 Feb 2003 00:21:38 -0000 1.233
+++ compiler/polymorphism.m 14 Mar 2003 09:58:29 -0000
@@ -160,8 +160,11 @@
:- module check_hlds__polymorphism.
:- interface.
-:- import_module hlds__hlds_goal, hlds__hlds_module, hlds__hlds_pred.
-:- import_module parse_tree__prog_data, hlds__special_pred.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__special_pred.
+:- import_module parse_tree__prog_data.
:- import_module io, list, term, map.
@@ -297,18 +300,27 @@
:- implementation.
-:- import_module hlds__hlds_data, check_hlds__typecheck, ll_backend__llds.
-:- import_module parse_tree__prog_io.
-:- import_module check_hlds__type_util, check_hlds__mode_util.
+:- import_module backend_libs__base_typeclass_info.
+:- import_module check_hlds__clause_to_proc.
+:- import_module check_hlds__mode_util.
:- import_module check_hlds__purity.
-:- import_module hlds__quantification, hlds__instmap, parse_tree__prog_out.
-:- import_module ll_backend__code_util, check_hlds__unify_proc.
-:- import_module parse_tree__prog_util.
-:- import_module (parse_tree__inst), hlds__hlds_out.
-:- import_module backend_libs__base_typeclass_info, hlds__goal_util.
+:- import_module check_hlds__type_util.
+:- import_module check_hlds__typecheck.
+:- import_module check_hlds__unify_proc.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_out.
+:- import_module hlds__instmap.
:- import_module hlds__passes_aux.
-:- import_module check_hlds__clause_to_proc.
-:- import_module libs__globals, libs__options.
+:- import_module hlds__quantification.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
:- import_module bool, int, string, set, map.
:- import_module term, varset, std_util, require, assoc_list.
Index: compiler/post_typecheck.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/post_typecheck.m,v
retrieving revision 1.46
diff -u -b -r1.46 post_typecheck.m
--- compiler/post_typecheck.m 28 Feb 2003 06:40:42 -0000 1.46
+++ compiler/post_typecheck.m 14 Mar 2003 09:58:52 -0000
@@ -30,8 +30,13 @@
:- module check_hlds__post_typecheck.
:- interface.
-:- import_module hlds__hlds_data, hlds__hlds_goal, hlds__hlds_module.
-:- import_module hlds__hlds_pred, parse_tree__prog_data.
+
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
+
:- import_module list, io, bool, std_util.
% post_typecheck__finish_preds(PredIds, ReportTypeErrors,
@@ -120,15 +125,24 @@
:- implementation.
-:- import_module (hlds__assertion).
-:- import_module check_hlds__typecheck, check_hlds__clause_to_proc.
-:- import_module check_hlds__mode_util, check_hlds__inst_match.
-:- import_module (parse_tree__inst), parse_tree__prog_util, hlds__error_util.
-:- import_module parse_tree__mercury_to_mercury, parse_tree__prog_out.
-:- import_module check_hlds__mode_errors, check_hlds__modecheck_call.
-:- import_module hlds__hlds_out, check_hlds__type_util, hlds__goal_util.
+:- import_module check_hlds__clause_to_proc.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_errors.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__modecheck_call.
+:- import_module check_hlds__type_util.
+:- import_module check_hlds__typecheck.
+:- import_module hlds__assertion.
+:- import_module hlds__error_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_out.
:- import_module hlds__special_pred.
-:- import_module libs__globals, libs__options.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
:- import_module map, set, assoc_list, term, require, int.
:- import_module string, varset.
Index: compiler/pragma_c_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/pragma_c_gen.m,v
retrieving revision 1.55
diff -u -b -r1.55 pragma_c_gen.m
--- compiler/pragma_c_gen.m 12 Feb 2003 22:58:11 -0000 1.55
+++ compiler/pragma_c_gen.m 14 Mar 2003 09:59:10 -0000
@@ -21,10 +21,12 @@
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_goal, hlds__hlds_pred.
:- import_module backend_libs__code_model.
-:- import_module ll_backend__llds, ll_backend__code_info.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_pred.
+:- import_module ll_backend__code_info.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__prog_data.
:- import_module list, std_util.
@@ -41,12 +43,20 @@
:- implementation.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_llds.
-:- import_module hlds__instmap, hlds__hlds_data, hlds__error_util.
-:- import_module check_hlds__type_util.
-:- import_module ll_backend__llds_out, ll_backend__trace, ll_backend__code_util.
:- import_module backend_libs__foreign.
-:- import_module libs__options, libs__globals, libs__tree.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_llds.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__tree.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__llds_out.
+:- import_module ll_backend__trace.
:- import_module bool, string, int, assoc_list, set, map, require, term.
Index: compiler/proc_label.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/proc_label.m,v
retrieving revision 1.1
diff -u -b -r1.1 proc_label.m
--- compiler/proc_label.m 14 Mar 2003 08:10:10 -0000 1.1
+++ compiler/proc_label.m 14 Mar 2003 09:59:20 -0000
@@ -17,6 +17,7 @@
:- module backend_libs__proc_label.
:- interface.
+
:- import_module backend_libs__rtti.
:- import_module hlds__hlds_module.
:- import_module hlds__hlds_pred.
Index: compiler/process_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/process_util.m,v
retrieving revision 1.9
diff -u -b -r1.9 process_util.m
--- compiler/process_util.m 3 Mar 2003 14:09:25 -0000 1.9
+++ compiler/process_util.m 14 Mar 2003 09:59:28 -0000
@@ -72,7 +72,9 @@
:- implementation.
-:- import_module libs__globals, libs__options.
+:- import_module libs__globals.
+:- import_module libs__options.
+
:- import_module std_util, require.
build_with_check_for_interrupt(Build, Cleanup, Succeeded, Info0, Info) -->
Index: compiler/prog_data.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/prog_data.m,v
retrieving revision 1.91
diff -u -b -r1.91 prog_data.m
--- compiler/prog_data.m 12 Feb 2003 22:58:11 -0000 1.91
+++ compiler/prog_data.m 14 Mar 2003 09:59:56 -0000
@@ -22,8 +22,11 @@
% Any types which are needed in both the parse tree and in the HLDS
% should be defined here, rather than in hlds*.m.
-:- import_module (parse_tree__inst), libs__options, libs__globals.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__inst.
:- import_module recompilation.
+
:- import_module bool, list, assoc_list, map, set, varset, term, std_util.
%-----------------------------------------------------------------------------%
@@ -1137,8 +1140,9 @@
:- implementation.
-:- import_module string.
:- import_module check_hlds__purity.
+
+:- import_module string.
:- type pragma_foreign_proc_attributes
---> attributes(
Index: compiler/prog_io.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/prog_io.m,v
retrieving revision 1.218
diff -u -b -r1.218 prog_io.m
--- compiler/prog_io.m 22 Feb 2003 13:18:27 -0000 1.218
+++ compiler/prog_io.m 14 Mar 2003 10:00:07 -0000
@@ -55,8 +55,10 @@
:- interface.
-:- import_module parse_tree__prog_data, parse_tree__prog_io_util.
-:- import_module libs__timestamp, (parse_tree__inst).
+:- import_module libs__timestamp.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_io_util.
:- import_module bool, varset, term, list, io, std_util.
Index: compiler/prog_io_dcg.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/prog_io_dcg.m,v
retrieving revision 1.20
diff -u -b -r1.20 prog_io_dcg.m
--- compiler/prog_io_dcg.m 9 Jul 2002 01:29:56 -0000 1.20
+++ compiler/prog_io_dcg.m 14 Mar 2003 10:00:26 -0000
@@ -19,7 +19,8 @@
:- interface.
-:- import_module parse_tree__prog_data, parse_tree__prog_io_util.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_io_util.
:- import_module varset, term.
:- pred parse_dcg_clause(module_name, varset, term, term,
@@ -38,8 +39,11 @@
:- implementation.
-:- import_module parse_tree__prog_io, parse_tree__prog_io_goal.
-:- import_module parse_tree__prog_util, check_hlds__purity.
+:- import_module check_hlds__purity.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_io_goal.
+:- import_module parse_tree__prog_util.
+
:- import_module int, map, string, std_util, list.
%-----------------------------------------------------------------------------%
Index: compiler/prog_io_goal.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/prog_io_goal.m,v
retrieving revision 1.23
diff -u -b -r1.23 prog_io_goal.m
--- compiler/prog_io_goal.m 9 Jul 2002 01:29:57 -0000 1.23
+++ compiler/prog_io_goal.m 14 Mar 2003 10:00:40 -0000
@@ -14,6 +14,7 @@
:- interface.
:- import_module parse_tree__prog_data.
+
:- import_module list, term.
% Convert a single term into a goal.
@@ -96,9 +97,12 @@
:- implementation.
-:- import_module check_hlds__mode_util, check_hlds__purity.
-:- import_module parse_tree__prog_io, parse_tree__prog_io_util.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__purity.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_io_util.
:- import_module transform_hlds__term_util.
+
:- import_module term.
:- import_module int, map, string, std_util.
Index: compiler/prog_io_pragma.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/prog_io_pragma.m,v
retrieving revision 1.56
diff -u -b -r1.56 prog_io_pragma.m
--- compiler/prog_io_pragma.m 12 Feb 2003 22:58:11 -0000 1.56
+++ compiler/prog_io_pragma.m 14 Mar 2003 10:00:50 -0000
@@ -13,7 +13,9 @@
:- interface.
-:- import_module parse_tree__prog_data, parse_tree__prog_io_util.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_io_util.
+
:- import_module list, varset, term.
% parse the pragma declaration.
@@ -22,9 +24,13 @@
:- implementation.
-:- import_module libs__globals, parse_tree__prog_io, parse_tree__prog_io_goal.
+:- import_module libs__globals.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_io_goal.
:- import_module parse_tree__prog_util.
-:- import_module transform_hlds__term_util, transform_hlds__term_errors.
+:- import_module transform_hlds__term_errors.
+:- import_module transform_hlds__term_util.
+
:- import_module int, map, string, std_util, bool, require, set.
parse_pragma(ModuleName, VarSet, PragmaTerms, Result) :-
Index: compiler/prog_io_typeclass.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/prog_io_typeclass.m,v
retrieving revision 1.27
diff -u -b -r1.27 prog_io_typeclass.m
--- compiler/prog_io_typeclass.m 17 Jan 2003 05:56:47 -0000 1.27
+++ compiler/prog_io_typeclass.m 14 Mar 2003 10:01:06 -0000
@@ -14,8 +14,9 @@
:- interface.
-:- import_module parse_tree__prog_data, parse_tree__prog_io_util.
-:- import_module (parse_tree__inst).
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_io_util.
:- import_module list, varset, term.
@@ -42,8 +43,11 @@
:- implementation.
-:- import_module parse_tree__prog_io, parse_tree__prog_io_goal.
-:- import_module parse_tree__prog_util, check_hlds__type_util, hlds__hlds_pred.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_io_goal.
+:- import_module parse_tree__prog_util.
:- import_module term, varset.
:- import_module int, string, std_util, require, set, map.
Index: compiler/prog_io_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/prog_io_util.m,v
retrieving revision 1.26
diff -u -b -r1.26 prog_io_util.m
--- compiler/prog_io_util.m 3 Mar 2003 03:25:13 -0000 1.26
+++ compiler/prog_io_util.m 14 Mar 2003 10:01:37 -0000
@@ -25,7 +25,9 @@
:- interface.
-:- import_module parse_tree__prog_data, (parse_tree__inst).
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+
:- import_module list, map, std_util, term, io.
:- type maybe2(T1, T2) ---> error(string, term)
@@ -167,14 +169,15 @@
:- implementation.
-:- import_module parse_tree__prog_io, parse_tree__prog_io_goal.
-:- import_module parse_tree__prog_util.
-:- import_module libs__options, libs__globals.
-
% XXX we should not need to import hlds*.m here.
% But currently we need to import hlds_data.m for the `cons_id' type
% that is used in insts.
:- import_module hlds__hlds_data.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_io_goal.
+:- import_module parse_tree__prog_util.
:- import_module bool, string, std_util, term, set.
Index: compiler/prog_out.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/prog_out.m,v
retrieving revision 1.48
diff -u -b -r1.48 prog_out.m
--- compiler/prog_out.m 17 Jan 2003 05:56:47 -0000 1.48
+++ compiler/prog_out.m 14 Mar 2003 10:01:53 -0000
@@ -18,7 +18,9 @@
%-----------------------------------------------------------------------------%
:- interface.
+
:- import_module parse_tree__prog_data.
+
:- import_module list, io.
:- pred prog_out__write_messages(message_list, io__state, io__state).
@@ -89,6 +91,7 @@
%-----------------------------------------------------------------------------%
:- implementation.
+
:- import_module term, varset, term_io.
:- import_module require, string, std_util, term, term_io, varset, int.
Index: compiler/prog_rep.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/prog_rep.m,v
retrieving revision 1.15
diff -u -b -r1.15 prog_rep.m
--- compiler/prog_rep.m 27 Jan 2003 09:20:50 -0000 1.15
+++ compiler/prog_rep.m 14 Mar 2003 10:02:09 -0000
@@ -18,10 +18,15 @@
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_pred, hlds__hlds_goal, hlds__hlds_module.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- import_module hlds__instmap.
-:- import_module mdb, mdb__program_representation.
+:- import_module parse_tree__prog_data.
+
+:- import_module mdb.
+:- import_module mdb__program_representation.
+
:- import_module list.
:- pred prog_rep__represent_proc(list(prog_var)::in, hlds_goal::in,
@@ -29,8 +34,9 @@
:- implementation.
-:- import_module parse_tree__prog_out.
:- import_module hlds__hlds_data.
+:- import_module parse_tree__prog_out.
+
:- import_module string, set, std_util, require, term.
:- type prog_rep__info
Index: compiler/prog_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/prog_util.m,v
retrieving revision 1.60
diff -u -b -r1.60 prog_util.m
--- compiler/prog_util.m 22 Feb 2003 13:18:28 -0000 1.60
+++ compiler/prog_util.m 14 Mar 2003 10:02:32 -0000
@@ -13,8 +13,9 @@
:- interface.
-:- import_module parse_tree__prog_data, term.
-:- import_module std_util, list.
+:- import_module parse_tree__prog_data.
+
+:- import_module std_util, list, term.
%-----------------------------------------------------------------------------%
@@ -200,7 +201,10 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module parse_tree__mercury_to_mercury, (parse_tree__inst).
+
+:- import_module parse_tree__inst.
+:- import_module parse_tree__mercury_to_mercury.
+
:- import_module bool, require, string, int, map, varset.
%-----------------------------------------------------------------------------%
Index: compiler/pseudo_type_info.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/pseudo_type_info.m,v
retrieving revision 1.10
diff -u -b -r1.10 pseudo_type_info.m
--- compiler/pseudo_type_info.m 27 Jan 2003 09:20:50 -0000 1.10
+++ compiler/pseudo_type_info.m 14 Mar 2003 10:02:42 -0000
@@ -16,7 +16,9 @@
:- module backend_libs__pseudo_type_info.
:- interface.
-:- import_module parse_tree__prog_data, backend_libs__rtti.
+
+:- import_module backend_libs__rtti.
+:- import_module parse_tree__prog_data.
% pseudo_type_info__construct_pseudo_type_info(Type,
% NumUnivQTvars, ExistQVars, PseudoTypeInfo)
@@ -58,7 +60,9 @@
:- implementation.
-:- import_module parse_tree__prog_util, check_hlds__type_util.
+:- import_module check_hlds__type_util.
+:- import_module parse_tree__prog_util.
+
:- import_module int, list, term, std_util, require.
%---------------------------------------------------------------------------%
Index: compiler/purity.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/purity.m,v
retrieving revision 1.54
diff -u -b -r1.54 purity.m
--- compiler/purity.m 28 Feb 2003 06:40:42 -0000 1.54
+++ compiler/purity.m 14 Mar 2003 10:03:00 -0000
@@ -118,8 +118,10 @@
:- module check_hlds__purity.
:- interface.
-:- import_module parse_tree__prog_data, hlds__hlds_module.
+:- import_module hlds__hlds_module.
:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
+
:- import_module io, bool.
% The purity type itself is defined in prog_data.m as follows:
@@ -180,16 +182,24 @@
:- implementation.
-:- import_module hlds__hlds_data, hlds__hlds_goal, parse_tree__prog_io_util.
-:- import_module check_hlds__type_util, check_hlds__mode_util.
-:- import_module parse_tree__prog_data.
+:- import_module check_hlds__clause_to_proc.
+:- import_module check_hlds__inst_util.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__post_typecheck.
+:- import_module check_hlds__type_util.
+:- import_module check_hlds__typecheck.
:- import_module check_hlds__unify_proc.
-:- import_module libs__globals, libs__options, parse_tree__mercury_to_mercury.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
:- import_module hlds__hlds_out.
-:- import_module hlds__passes_aux, check_hlds__typecheck.
-:- import_module parse_tree__module_qual, check_hlds__clause_to_proc.
-:- import_module check_hlds__inst_util, parse_tree__prog_out.
-:- import_module check_hlds__post_typecheck.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__module_qual.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_io_util.
+:- import_module parse_tree__prog_out.
:- import_module map, varset, term, string, require, std_util.
:- import_module assoc_list, bool, int, list, set.
Index: compiler/quantification.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/quantification.m,v
retrieving revision 1.84
diff -u -b -r1.84 quantification.m
--- compiler/quantification.m 27 Jan 2003 09:20:50 -0000 1.84
+++ compiler/quantification.m 14 Mar 2003 10:03:16 -0000
@@ -38,7 +38,10 @@
:- interface.
-:- import_module hlds__hlds_goal, hlds__hlds_pred, parse_tree__prog_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
+
:- import_module list, set.
%
@@ -120,7 +123,8 @@
:- implementation.
-:- import_module hlds__instmap, hlds__goal_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__instmap.
:- import_module map, term, varset.
:- import_module std_util, bool, require.
Index: compiler/reassign.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/reassign.m,v
retrieving revision 1.4
diff -u -b -r1.4 reassign.m
--- compiler/reassign.m 14 Apr 2002 04:07:08 -0000 1.4
+++ compiler/reassign.m 14 Mar 2003 10:03:22 -0000
@@ -99,6 +99,7 @@
:- interface.
:- import_module ll_backend__llds.
+
:- import_module list.
:- pred remove_reassign(list(instruction)::in, list(instruction)::out) is det.
@@ -106,6 +107,7 @@
:- implementation.
:- import_module ll_backend__code_util.
+
:- import_module std_util, set, map, require.
%-----------------------------------------------------------------------------%
Index: compiler/recompilation.check.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/recompilation.check.m,v
retrieving revision 1.1
diff -u -b -r1.1 recompilation.check.m
--- compiler/recompilation.check.m 20 Mar 2002 12:37:17 -0000 1.1
+++ compiler/recompilation.check.m 14 Mar 2003 10:03:57 -0000
@@ -12,8 +12,10 @@
:- interface.
-:- import_module parse_tree__modules, parse_tree__prog_io.
+:- import_module parse_tree__modules.
:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_io.
+
:- import_module list, io.
:- type modules_to_recompile
@@ -54,15 +56,18 @@
:- implementation.
-:- import_module recompilation__usage.
-:- import_module recompilation__version.
-:- import_module libs__timestamp.
-:- import_module parse_tree__prog_io_util, parse_tree__prog_util.
-:- import_module parse_tree__prog_out, hlds__error_util.
-:- import_module libs__globals, libs__options.
+:- import_module hlds__error_util.
+:- import_module hlds__hlds_data. % for type field_access_type
:- import_module hlds__hlds_pred. % for field_access_function_name,
% type pred_id.
-:- import_module hlds__hlds_data. % for type field_access_type
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__timestamp.
+:- import_module parse_tree__prog_io_util.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
+:- import_module recompilation__usage.
+:- import_module recompilation__version.
:- import_module assoc_list, bool, exception, int, map, parser, require.
:- import_module set, std_util, string, term, term_io.
Index: compiler/recompilation.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/recompilation.m,v
retrieving revision 1.6
diff -u -b -r1.6 recompilation.m
--- compiler/recompilation.m 29 Jul 2002 16:28:30 -0000 1.6
+++ compiler/recompilation.m 14 Mar 2003 10:04:46 -0000
@@ -24,17 +24,19 @@
:- interface.
-:- import_module parse_tree.
:- import_module hlds.
:- import_module libs.
+:- import_module parse_tree.
+
+:- import_module libs__timestamp.
+:- import_module parse_tree__prog_data.
+
+:- import_module io, map, set, std_util, term.
:- include_module recompilation__check.
:- include_module recompilation__usage.
:- include_module recompilation__version.
-:- import_module parse_tree__prog_data, libs__timestamp.
-:- import_module io, map, set, std_util, term.
-
% Identify a particular version of a program item.
% This could be done using a timestamp or a hash value.
:- type version_number == timestamp.
@@ -242,9 +244,12 @@
:- implementation.
-:- import_module parse_tree__prog_util.
-:- import_module libs__globals, libs__options, hlds__passes_aux.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_util.
+
:- import_module int, time, bool, list, require, string.
%-----------------------------------------------------------------------------%
Index: compiler/recompilation.usage.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/recompilation.usage.m,v
retrieving revision 1.6
diff -u -b -r1.6 recompilation.usage.m
--- compiler/recompilation.usage.m 22 Feb 2003 13:18:28 -0000 1.6
+++ compiler/recompilation.usage.m 14 Mar 2003 10:05:05 -0000
@@ -12,7 +12,9 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, parse_tree__modules.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__modules.
:- import_module parse_tree__prog_data.
:- import_module assoc_list, io, list, map, set, std_util.
@@ -77,12 +79,19 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module hlds__hlds_data, hlds__hlds_pred, parse_tree__prog_util.
-:- import_module check_hlds__type_util, (parse_tree__inst).
-:- import_module hlds__hlds_out, parse_tree__mercury_to_mercury.
-:- import_module hlds__passes_aux, parse_tree__prog_data.
-:- import_module libs__globals, libs__options.
-:- import_module recompilation__version, libs__timestamp.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_out.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__timestamp.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_util.
+:- import_module recompilation__version.
:- import_module assoc_list, bool, int, require.
:- import_module queue, std_util, string.
Index: compiler/recompilation.version.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/recompilation.version.m,v
retrieving revision 1.4
diff -u -b -r1.4 recompilation.version.m
--- compiler/recompilation.version.m 12 Feb 2003 22:58:12 -0000 1.4
+++ compiler/recompilation.version.m 14 Mar 2003 10:05:19 -0000
@@ -12,8 +12,10 @@
:- interface.
+:- import_module libs__timestamp.
:- import_module parse_tree__prog_data.
-:- import_module parse_tree__prog_io_util, libs__timestamp.
+:- import_module parse_tree__prog_io_util.
+
:- import_module io, std_util, term.
% recompilation__version__compute_version_numbers(SourceFileModTime,
@@ -34,10 +36,13 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module parse_tree__mercury_to_mercury, check_hlds__mode_util.
-:- import_module parse_tree__prog_io, parse_tree__prog_util.
+:- import_module check_hlds__mode_util.
:- import_module check_hlds__type_util.
-:- import_module hlds__hlds_out, (parse_tree__inst).
+:- import_module hlds__hlds_out.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_util.
:- import_module assoc_list, bool, list, map, require, string, varset.
Index: compiler/rl_analyse.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rl_analyse.m,v
retrieving revision 1.3
diff -u -b -r1.3 rl_analyse.m
--- compiler/rl_analyse.m 20 Mar 2002 12:37:18 -0000 1.3
+++ compiler/rl_analyse.m 14 Mar 2003 10:05:36 -0000
@@ -14,6 +14,7 @@
:- interface.
:- import_module aditi_backend__rl_block.
+
:- import_module io, list, map, set, std_util.
% rl_analyse(Blocks, Direction, Init, Confluence, Update, Results,
@@ -106,7 +107,9 @@
:- implementation.
-:- import_module libs__globals, libs__options.
+:- import_module libs__globals.
+:- import_module libs__options.
+
:- import_module assoc_list, bool, relation, require, string.
rl_analyse(Blocks, Analysis, BlockDataMap0, BlockDataMap,
Index: compiler/rl_block.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rl_block.m,v
retrieving revision 1.3
diff -u -b -r1.3 rl_block.m
--- compiler/rl_block.m 20 Mar 2002 12:37:18 -0000 1.3
+++ compiler/rl_block.m 14 Mar 2003 10:05:50 -0000
@@ -14,8 +14,11 @@
:- interface.
-:- import_module aditi_backend__rl, hlds__hlds_pred, hlds__hlds_module.
+:- import_module aditi_backend__rl.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- import_module parse_tree__prog_data.
+
:- import_module bool, io, int, list, map, relation, set, std_util.
:- pred rl_block__create_flow_graph(bool::in, module_info::in,
@@ -37,7 +40,9 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module hlds__hlds_module, aditi_backend__rl_dump.
+:- import_module aditi_backend__rl_dump.
+:- import_module hlds__hlds_module.
+
:- import_module queue, require, string.
rl_block__create_flow_graph(Debug, ModuleInfo, Proc, Info) -->
Index: compiler/rl_block_opt.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rl_block_opt.m,v
retrieving revision 1.8
diff -u -b -r1.8 rl_block_opt.m
--- compiler/rl_block_opt.m 20 Mar 2002 12:37:19 -0000 1.8
+++ compiler/rl_block_opt.m 14 Mar 2003 10:06:07 -0000
@@ -39,10 +39,17 @@
:- implementation.
-:- import_module hlds__goal_util, hlds__hlds_goal, hlds__hlds_module.
-:- import_module hlds__hlds_pred, transform_hlds__inlining.
-:- import_module parse_tree__prog_data, aditi_backend__rl.
-:- import_module aditi_backend__rl_key, libs__globals, libs__options.
+:- import_module aditi_backend__rl.
+:- import_module aditi_backend__rl_key.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__prog_data.
+:- import_module transform_hlds__inlining.
+
:- import_module assoc_list, bool, int, map, multi_map.
:- import_module relation, require, set, std_util, string.
Index: compiler/rl_dump.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rl_dump.m,v
retrieving revision 1.8
diff -u -b -r1.8 rl_dump.m
--- compiler/rl_dump.m 20 Mar 2002 12:37:19 -0000 1.8
+++ compiler/rl_dump.m 14 Mar 2003 10:06:28 -0000
@@ -13,7 +13,9 @@
:- interface.
-:- import_module hlds__hlds_module, aditi_backend__rl.
+:- import_module aditi_backend__rl.
+:- import_module hlds__hlds_module.
+
:- import_module io.
:- pred rl_dump__write_procedure(module_info, rl_proc, io__state, io__state).
@@ -26,8 +28,11 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module hlds__hlds_out, hlds__hlds_pred.
-:- import_module parse_tree__mercury_to_mercury, parse_tree__prog_data.
+:- import_module hlds__hlds_out.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_data.
+
:- import_module bool, list, map, require, set, std_util.
:- import_module term, term_io, varset.
Index: compiler/rl_exprn.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rl_exprn.m,v
retrieving revision 1.27
diff -u -b -r1.27 rl_exprn.m
--- compiler/rl_exprn.m 28 Feb 2003 06:40:42 -0000 1.27
+++ compiler/rl_exprn.m 14 Mar 2003 10:06:48 -0000
@@ -51,9 +51,13 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, aditi_backend__rl.
-:- import_module aditi_backend__rl_code, aditi_backend__rl_file.
+:- import_module aditi_backend__rl.
+:- import_module aditi_backend__rl_code.
+:- import_module aditi_backend__rl_file.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- import_module parse_tree__prog_data.
+
:- import_module list.
% rl_exprn__generate_compare_exprn(ModuleInfo, SortSpec,
@@ -126,13 +130,20 @@
:- implementation.
-:- import_module hlds__hlds_pred, hlds__hlds_data.
-:- import_module check_hlds__inst_match.
-:- import_module hlds__instmap, check_hlds__mode_util, libs__tree.
-:- import_module check_hlds__type_util, parse_tree__prog_out.
-:- import_module aditi_backend__rl_out, transform_hlds__inlining.
-:- import_module hlds__hlds_goal, parse_tree__prog_util, hlds__error_util.
+:- import_module aditi_backend__rl_out.
:- import_module backend_libs__builtin_ops.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module libs__tree.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
+:- import_module transform_hlds__inlining.
:- import_module assoc_list, bool, char, int, map.
:- import_module require, set, std_util, string, term, varset.
Index: compiler/rl_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rl_gen.m,v
retrieving revision 1.9
diff -u -b -r1.9 rl_gen.m
--- compiler/rl_gen.m 27 Jan 2003 09:20:50 -0000 1.9
+++ compiler/rl_gen.m 14 Mar 2003 10:07:14 -0000
@@ -16,7 +16,9 @@
:- interface.
-:- import_module hlds__hlds_module, aditi_backend__rl.
+:- import_module aditi_backend__rl.
+:- import_module hlds__hlds_module.
+
:- import_module io.
:- pred rl_gen__module(module_info, rl_code, io__state, io__state).
@@ -25,15 +27,27 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module ll_backend__code_aux, ll_backend__code_util.
-:- import_module check_hlds__det_analysis, hlds__hlds_data, hlds__hlds_goal.
-:- import_module hlds__hlds_pred, hlds__instmap, check_hlds__mode_util.
-:- import_module parse_tree__prog_data, parse_tree__prog_out.
-:- import_module aditi_backend__rl_relops, aditi_backend__rl_info.
-:- import_module libs__tree, check_hlds__type_util.
+:- import_module aditi_backend__rl_info.
+:- import_module aditi_backend__rl_relops.
+:- import_module check_hlds__det_analysis.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__tree.
+:- import_module ll_backend__code_aux.
+:- import_module ll_backend__code_util.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
:- import_module transform_hlds__dependency_graph.
-:- import_module check_hlds__inst_match, (parse_tree__inst), hlds__goal_util.
-:- import_module transform_hlds__inlining, libs__globals, libs__options.
+:- import_module transform_hlds__inlining.
:- import_module assoc_list, bool, char, int, list, map, queue.
:- import_module relation, require, set, std_util, string, term, varset.
Index: compiler/rl_info.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rl_info.m,v
retrieving revision 1.2
diff -u -b -r1.2 rl_info.m
--- compiler/rl_info.m 20 Mar 2002 12:37:19 -0000 1.2
+++ compiler/rl_info.m 14 Mar 2003 10:07:34 -0000
@@ -12,8 +12,12 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, parse_tree__prog_data.
-:- import_module aditi_backend__rl, libs__tree.
+:- import_module aditi_backend__rl.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module libs__tree.
+:- import_module parse_tree__prog_data.
+
:- import_module bool, io, list, map, set, std_util, string.
:- type rl_info.
@@ -236,9 +240,15 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module ll_backend__code_util, libs__globals, ll_backend__llds_out.
-:- import_module check_hlds__mode_util, libs__options, check_hlds__type_util.
-:- import_module hlds__hlds_goal, parse_tree__prog_out.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_goal.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__llds_out.
+:- import_module parse_tree__prog_out.
+
:- import_module int, require.
:- type rl_info
Index: compiler/rl_key.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rl_key.m,v
retrieving revision 1.12
diff -u -b -r1.12 rl_key.m
--- compiler/rl_key.m 30 Jun 2002 17:06:39 -0000 1.12
+++ compiler/rl_key.m 14 Mar 2003 10:07:47 -0000
@@ -17,8 +17,11 @@
:- interface.
-:- import_module hlds__hlds_goal, hlds__hlds_module, parse_tree__prog_data.
:- import_module aditi_backend__rl.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module parse_tree__prog_data.
+
:- import_module list, map.
% Work out the upper and lower bounds for the inputs to an
@@ -52,8 +55,11 @@
:- implementation.
-:- import_module hlds__hlds_data, hlds__hlds_pred, parse_tree__prog_util.
:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_util.
+
:- import_module assoc_list, bool, int, require, set, std_util.
rl_key__extract_indexing(no_inputs, _, _, _, []).
Index: compiler/rl_liveness.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rl_liveness.m,v
retrieving revision 1.4
diff -u -b -r1.4 rl_liveness.m
--- compiler/rl_liveness.m 20 Mar 2002 12:37:20 -0000 1.4
+++ compiler/rl_liveness.m 14 Mar 2003 10:07:54 -0000
@@ -19,6 +19,7 @@
:- interface.
:- import_module aditi_backend__rl_block.
+
:- import_module io.
:- pred rl_liveness(rl_opt_info, rl_opt_info, io__state, io__state).
@@ -27,7 +28,9 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module aditi_backend__rl, aditi_backend__rl_analyse.
+:- import_module aditi_backend__rl.
+:- import_module aditi_backend__rl_analyse.
+
:- import_module bool, int, list, map, relation, require, set, std_util.
rl_liveness(Opt0, Opt, IO0, IO) :-
Index: compiler/rl_loop.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rl_loop.m,v
retrieving revision 1.2
diff -u -b -r1.2 rl_loop.m
--- compiler/rl_loop.m 20 Mar 2002 12:37:20 -0000 1.2
+++ compiler/rl_loop.m 14 Mar 2003 10:07:59 -0000
@@ -27,6 +27,7 @@
:- implementation.
:- import_module aditi_backend__rl.
+
:- import_module assoc_list, bimap, bool, int, list, map, queue, relation.
:- import_module require, set, std_util.
Index: compiler/rl_opt.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rl_opt.m,v
retrieving revision 1.4
diff -u -b -r1.4 rl_opt.m
--- compiler/rl_opt.m 20 Mar 2002 12:37:20 -0000 1.4
+++ compiler/rl_opt.m 14 Mar 2003 10:08:10 -0000
@@ -12,7 +12,9 @@
:- interface.
-:- import_module hlds__hlds_module, aditi_backend__rl.
+:- import_module aditi_backend__rl.
+:- import_module hlds__hlds_module.
+
:- import_module io, list.
:- pred rl_opt__procs(module_info, list(rl_proc), list(rl_proc),
@@ -22,11 +24,17 @@
%-----------------------------------------------------------------------------%
:- implementation.
-:- import_module libs__globals, libs__options, hlds__passes_aux.
+:- import_module aditi_backend__rl_block.
+:- import_module aditi_backend__rl_block_opt.
+:- import_module aditi_backend__rl_liveness.
+:- import_module aditi_backend__rl_loop.
+:- import_module aditi_backend__rl_sort.
+:- import_module aditi_backend__rl_stream.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
:- import_module parse_tree__prog_out.
-:- import_module aditi_backend__rl_block, aditi_backend__rl_liveness.
-:- import_module aditi_backend__rl_block_opt, aditi_backend__rl_loop.
-:- import_module aditi_backend__rl_sort, aditi_backend__rl_stream.
+
:- import_module bool, list.
rl_opt__procs(ModuleInfo, Procs0, Procs) -->
Index: compiler/rl_relops.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rl_relops.m,v
retrieving revision 1.6
diff -u -b -r1.6 rl_relops.m
--- compiler/rl_relops.m 20 Mar 2002 12:37:20 -0000 1.6
+++ compiler/rl_relops.m 14 Mar 2003 10:08:35 -0000
@@ -12,8 +12,12 @@
:- interface.
-:- import_module hlds__hlds_goal, hlds__instmap, parse_tree__prog_data.
-:- import_module aditi_backend__rl, aditi_backend__rl_info.
+:- import_module aditi_backend__rl.
+:- import_module aditi_backend__rl_info.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__instmap.
+:- import_module parse_tree__prog_data.
+
:- import_module bool, list, std_util.
/*
@@ -96,10 +100,16 @@
:- implementation.
-:- import_module ll_backend__code_aux, hlds__hlds_data, hlds__hlds_module.
-:- import_module hlds__hlds_pred, check_hlds__mode_util.
-:- import_module libs__tree, aditi_backend__rl_key, libs__globals.
+:- import_module aditi_backend__rl_key.
+:- import_module check_hlds__mode_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module libs__globals.
:- import_module libs__options.
+:- import_module libs__tree.
+:- import_module ll_backend__code_aux.
+
:- import_module int, map, require, set.
%-----------------------------------------------------------------------------%
Index: compiler/rl_sort.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rl_sort.m,v
retrieving revision 1.10
diff -u -b -r1.10 rl_sort.m
--- compiler/rl_sort.m 20 Mar 2002 12:37:20 -0000 1.10
+++ compiler/rl_sort.m 14 Mar 2003 10:08:48 -0000
@@ -35,6 +35,7 @@
:- interface.
:- import_module aditi_backend__rl_block.
+
:- import_module io.
:- pred rl_sort__proc(rl_opt_info, rl_opt_info, io__state, io__state).
@@ -44,8 +45,12 @@
:- implementation.
-:- import_module hlds__hlds_module, parse_tree__prog_data, aditi_backend__rl.
-:- import_module aditi_backend__rl_analyse, aditi_backend__rl_key.
+:- import_module aditi_backend__rl.
+:- import_module aditi_backend__rl_analyse.
+:- import_module aditi_backend__rl_key.
+:- import_module hlds__hlds_module.
+:- import_module parse_tree__prog_data.
+
:- import_module assoc_list, bool, int, list, map, relation, require, set.
:- import_module std_util.
Index: compiler/rl_stream.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rl_stream.m,v
retrieving revision 1.7
diff -u -b -r1.7 rl_stream.m
--- compiler/rl_stream.m 20 Mar 2002 12:37:20 -0000 1.7
+++ compiler/rl_stream.m 14 Mar 2003 10:08:54 -0000
@@ -42,6 +42,7 @@
:- implementation.
:- import_module aditi_backend__rl.
+
:- import_module assoc_list, bag, int, list, map, multi_map.
:- import_module relation, require, set, std_util.
Index: compiler/rtti.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rtti.m,v
retrieving revision 1.26
diff -u -b -r1.26 rtti.m
--- compiler/rtti.m 14 Mar 2003 08:10:10 -0000 1.26
+++ compiler/rtti.m 14 Mar 2003 10:09:15 -0000
@@ -24,9 +24,11 @@
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_data.
:- import_module backend_libs__code_model.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
:- import_module assoc_list, bool, list, set, map, std_util.
@@ -629,10 +631,11 @@
:- implementation.
-:- import_module parse_tree__prog_util. % for mercury_public_builtin_module
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
:- import_module hlds__hlds_data.
-:- import_module check_hlds__type_util, check_hlds__mode_util.
:- import_module ll_backend__llds_out. % for name_mangle and sym_name_mangle
+:- import_module parse_tree__prog_util. % for mercury_public_builtin_module
:- import_module int, string, require, varset.
Index: compiler/rtti_out.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rtti_out.m,v
retrieving revision 1.32
diff -u -b -r1.32 rtti_out.m
--- compiler/rtti_out.m 26 Feb 2003 06:36:24 -0000 1.32
+++ compiler/rtti_out.m 14 Mar 2003 10:09:34 -0000
@@ -23,8 +23,11 @@
:- interface.
-:- import_module parse_tree__prog_data, hlds__hlds_data.
-:- import_module backend_libs__rtti, ll_backend__llds_out.
+:- import_module backend_libs__rtti.
+:- import_module hlds__hlds_data.
+:- import_module ll_backend__llds_out.
+:- import_module parse_tree__prog_data.
+
:- import_module bool, io.
% Output a C expression holding the address of the C name of
@@ -79,12 +82,16 @@
:- implementation.
-:- import_module parse_tree__prog_out.
-:- import_module hlds__error_util.
-:- import_module backend_libs__pseudo_type_info, backend_libs__type_ctor_info.
:- import_module backend_libs__c_util.
-:- import_module ll_backend__llds, ll_backend__code_util.
-:- import_module libs__options, libs__globals.
+:- import_module backend_libs__pseudo_type_info.
+:- import_module backend_libs__type_ctor_info.
+:- import_module hlds__error_util.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__prog_out.
+
:- import_module int, string, list, assoc_list, map, require, std_util.
%-----------------------------------------------------------------------------%
Index: compiler/rtti_to_mlds.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/rtti_to_mlds.m,v
retrieving revision 1.37
diff -u -b -r1.37 rtti_to_mlds.m
--- compiler/rtti_to_mlds.m 26 Feb 2003 06:36:25 -0000 1.37
+++ compiler/rtti_to_mlds.m 14 Mar 2003 10:09:54 -0000
@@ -16,21 +16,31 @@
:- module ml_backend__rtti_to_mlds.
:- interface.
-:- import_module hlds__hlds_module, backend_libs__rtti, ml_backend__mlds.
+
+:- import_module backend_libs__rtti.
+:- import_module hlds__hlds_module.
+:- import_module ml_backend__mlds.
+
:- import_module list.
% return a list of MLDS definitions for the given rtti_data list.
:- func rtti_data_list_to_mlds(module_info, list(rtti_data)) = mlds__defns.
:- implementation.
-:- import_module parse_tree__prog_data, parse_tree__prog_data.
-:- import_module parse_tree__prog_out, parse_tree__prog_util.
-:- import_module hlds__hlds_data.
-:- import_module check_hlds__type_util.
-:- import_module backend_libs__foreign, backend_libs__type_ctor_info.
+
+:- import_module backend_libs__foreign.
:- import_module backend_libs__pseudo_type_info.
-:- import_module ml_backend__ml_code_util, ml_backend__ml_unify_gen.
+:- import_module backend_libs__type_ctor_info.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
:- import_module ml_backend__ml_closure_gen.
+:- import_module ml_backend__ml_code_util.
+:- import_module ml_backend__ml_unify_gen.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
+
:- import_module bool, string, int, list, assoc_list, map.
:- import_module std_util, term, require.
Index: compiler/saved_vars.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/saved_vars.m,v
retrieving revision 1.33
diff -u -b -r1.33 saved_vars.m
--- compiler/saved_vars.m 28 Mar 2002 03:43:36 -0000 1.33
+++ compiler/saved_vars.m 14 Mar 2003 10:10:11 -0000
@@ -25,7 +25,9 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+
:- import_module io.
:- pred saved_vars_proc(pred_id::in, proc_id::in,
@@ -39,9 +41,15 @@
:- implementation.
-:- import_module hlds__hlds_goal, hlds__hlds_out, hlds__goal_util.
-:- import_module hlds__quantification, hlds__passes_aux.
-:- import_module check_hlds__mode_util, parse_tree__prog_data, term, varset.
+:- import_module check_hlds__mode_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_out.
+:- import_module hlds__passes_aux.
+:- import_module hlds__quantification.
+:- import_module parse_tree__prog_data.
+
+:- import_module term, varset.
:- import_module bool, list, set, map, std_util, require.
%-----------------------------------------------------------------------------%
Index: compiler/simplify.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/simplify.m,v
retrieving revision 1.113
diff -u -b -r1.113 simplify.m
--- compiler/simplify.m 28 Feb 2003 06:40:43 -0000 1.113
+++ compiler/simplify.m 14 Mar 2003 10:10:34 -0000
@@ -28,10 +28,16 @@
:- interface.
-:- import_module hlds__hlds_goal, hlds__hlds_module, hlds__hlds_pred.
-:- import_module check_hlds__det_report, check_hlds__det_util.
-:- import_module check_hlds__common, hlds__instmap, libs__globals.
+:- import_module check_hlds__common.
+:- import_module check_hlds__det_report.
:- import_module check_hlds__det_util.
+:- import_module check_hlds__det_util.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module libs__globals.
+
:- import_module io, bool, list, map.
:- pred simplify__pred(list(simplification), pred_id, module_info, module_info,
@@ -75,21 +81,30 @@
:- implementation.
-:- import_module parse_tree__inst, parse_tree__prog_data.
-:- import_module parse_tree__prog_util.
-:- import_module hlds__hlds_module, hlds__hlds_data, hlds__passes_aux.
-:- import_module hlds__goal_util, hlds__goal_form, hlds__special_pred.
-:- import_module hlds__quantification.
-:- import_module check_hlds__type_util.
-:- import_module check_hlds__mode_util, check_hlds__inst_match.
:- import_module check_hlds__det_analysis.
-:- import_module check_hlds__modes, check_hlds__purity.
-:- import_module check_hlds__unify_proc.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__modes.
:- import_module check_hlds__polymorphism.
+:- import_module check_hlds__purity.
+:- import_module check_hlds__type_util.
+:- import_module check_hlds__unify_proc.
+:- import_module hlds__goal_form.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__passes_aux.
+:- import_module hlds__quantification.
+:- import_module hlds__special_pred.
+:- import_module libs__options.
+:- import_module libs__trace_params.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__follow_code.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_util.
:- import_module transform_hlds__const_prop.
:- import_module transform_hlds__pd_cost.
-:- import_module ll_backend__code_util, ll_backend__follow_code.
-:- import_module libs__options, libs__trace_params.
:- import_module int, set, require, std_util, string, varset, term.
Index: compiler/source_file_map.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/source_file_map.m,v
retrieving revision 1.5
diff -u -b -r1.5 source_file_map.m
--- compiler/source_file_map.m 17 Jan 2003 05:56:48 -0000 1.5
+++ compiler/source_file_map.m 14 Mar 2003 10:10:44 -0000
@@ -12,7 +12,9 @@
:- interface.
-:- import_module parse_tree__prog_data, parse_tree__prog_io.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_io.
+
:- import_module bool, io, list.
% lookup_module_source_file(ModuleName, FileName, FileNameIsMapped).
@@ -36,9 +38,12 @@
:- implementation.
-:- import_module parse_tree__prog_out, parse_tree__prog_util.
+:- import_module libs__globals.
+:- import_module libs__options.
:- import_module parse_tree__modules.
-:- import_module libs__globals, libs__options.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
+
:- import_module char, dir, map, std_util, string.
lookup_module_source_file(ModuleName, FileName) -->
Index: compiler/special_pred.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/special_pred.m,v
retrieving revision 1.35
diff -u -b -r1.35 special_pred.m
--- compiler/special_pred.m 12 Feb 2003 22:58:12 -0000 1.35
+++ compiler/special_pred.m 14 Mar 2003 10:11:03 -0000
@@ -15,8 +15,12 @@
:- module hlds__special_pred.
:- interface.
-:- import_module parse_tree__prog_data, hlds__hlds_data, hlds__hlds_module.
+
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
+
:- import_module list, map, std_util.
:- type special_pred_map == map(special_pred, pred_id).
@@ -105,9 +109,12 @@
:- implementation.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module libs__globals.
+:- import_module libs__options.
:- import_module parse_tree__prog_util.
-:- import_module check_hlds__type_util, check_hlds__mode_util.
-:- import_module libs__globals, libs__options.
+
:- import_module bool, require.
special_pred_list([unify, index, compare]).
Index: compiler/stack_alloc.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/stack_alloc.m,v
retrieving revision 1.2
diff -u -b -r1.2 stack_alloc.m
--- compiler/stack_alloc.m 30 Jul 2002 08:25:10 -0000 1.2
+++ compiler/stack_alloc.m 14 Mar 2003 10:11:15 -0000
@@ -25,7 +25,9 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+
:- import_module io.
:- pred allocate_stack_slots_in_proc(pred_id::in, proc_id::in, module_info::in,
@@ -36,16 +38,21 @@
:- implementation.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_goal, hlds__hlds_llds.
-:- import_module hlds__hlds_data.
+:- import_module backend_libs__code_model.
:- import_module check_hlds__goal_path.
-:- import_module ll_backend__llds, ll_backend__stack_opt.
-:- import_module ll_backend__liveness, ll_backend__live_vars.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_llds.
+:- import_module libs__globals.
+:- import_module libs__graph_colour.
+:- import_module libs__options.
+:- import_module libs__trace_params.
+:- import_module ll_backend__live_vars.
+:- import_module ll_backend__liveness.
+:- import_module ll_backend__llds.
+:- import_module ll_backend__stack_opt.
:- import_module ll_backend__trace.
-:- import_module backend_libs__code_model.
-:- import_module libs__globals, libs__options.
-:- import_module libs__trace_params, libs__graph_colour.
+:- import_module parse_tree__prog_data.
:- import_module bool, int, list, assoc_list, map, set, std_util, require.
Index: compiler/stack_opt.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/stack_opt.m,v
retrieving revision 1.5
diff -u -b -r1.5 stack_opt.m
--- compiler/stack_opt.m 14 Jan 2003 16:42:29 -0000 1.5
+++ compiler/stack_opt.m 14 Mar 2003 10:11:37 -0000
@@ -71,7 +71,9 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+
:- import_module io.
:- pred stack_opt_cell(pred_id::in, proc_id::in, proc_info::in, proc_info::out,
@@ -82,18 +84,28 @@
:- implementation.
-:- import_module parse_tree__prog_data, parse_tree__mercury_to_mercury.
-:- import_module hlds__hlds_data, hlds__hlds_goal, hlds__hlds_llds.
-:- import_module hlds__quantification, hlds__instmap.
-:- import_module hlds__goal_util, hlds__hlds_out.
-:- import_module check_hlds__type_util, check_hlds__mode_util.
-:- import_module check_hlds__inst_match, check_hlds__goal_path.
-:- import_module ll_backend__arg_info, ll_backend__call_gen.
-:- import_module ll_backend__liveness, ll_backend__live_vars.
-:- import_module ll_backend__store_alloc.
:- import_module backend_libs__code_model.
:- import_module backend_libs__matching.
-:- import_module libs__globals, libs__options.
+:- import_module check_hlds__goal_path.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_llds.
+:- import_module hlds__hlds_out.
+:- import_module hlds__instmap.
+:- import_module hlds__quantification.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ll_backend__arg_info.
+:- import_module ll_backend__call_gen.
+:- import_module ll_backend__live_vars.
+:- import_module ll_backend__liveness.
+:- import_module ll_backend__store_alloc.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_data.
:- import_module counter, bool, int, list, assoc_list.
:- import_module map, set, std_util, require, term, varset.
Index: compiler/static_term.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/static_term.m,v
retrieving revision 1.3
diff -u -b -r1.3 static_term.m
--- compiler/static_term.m 20 Mar 2002 12:37:24 -0000 1.3
+++ compiler/static_term.m 14 Mar 2003 10:11:42 -0000
@@ -18,6 +18,7 @@
:- interface.
:- import_module ll_backend__llds.
+
:- import_module counter, std_util.
:- pred static_term__term_to_rval(univ::in, maybe(rval)::out,
@@ -28,6 +29,7 @@
:- implementation.
:- import_module backend_libs__builtin_ops.
+
:- import_module deconstruct, list, require.
static_term__term_to_rval(Univ, Rval, CellCounter0, CellCounter) :-
Index: compiler/store_alloc.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/store_alloc.m,v
retrieving revision 1.80
diff -u -b -r1.80 store_alloc.m
--- compiler/store_alloc.m 30 Jul 2002 08:25:11 -0000 1.80
+++ compiler/store_alloc.m 14 Mar 2003 10:11:54 -0000
@@ -26,7 +26,8 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- type store_map_run_type
---> final_allocation
@@ -40,13 +41,20 @@
:- implementation.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_goal, hlds__hlds_llds.
-:- import_module hlds__goal_util, hlds__instmap.
:- import_module check_hlds__mode_util.
-:- import_module ll_backend__llds, ll_backend__trace, ll_backend__arg_info.
-:- import_module ll_backend__follow_vars, ll_backend__liveness.
-:- import_module libs__options, libs__globals, libs__trace_params.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_llds.
+:- import_module hlds__instmap.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__trace_params.
+:- import_module ll_backend__arg_info.
+:- import_module ll_backend__follow_vars.
+:- import_module ll_backend__liveness.
+:- import_module ll_backend__llds.
+:- import_module ll_backend__trace.
+:- import_module parse_tree__prog_data.
:- import_module bool, int, require.
:- import_module list, map, set, std_util, assoc_list.
Index: compiler/stratify.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/stratify.m,v
retrieving revision 1.28
diff -u -b -r1.28 stratify.m
--- compiler/stratify.m 27 Jan 2003 09:20:52 -0000 1.28
+++ compiler/stratify.m 14 Mar 2003 10:12:07 -0000
@@ -33,7 +33,9 @@
:- interface.
-:- import_module hlds__hlds_module, io.
+:- import_module hlds__hlds_module.
+
+:- import_module io.
% Perform stratification analysis, for the given module.
% If the "warn-non-stratification" option is set this
@@ -46,12 +48,18 @@
:- implementation.
-:- import_module transform_hlds__dependency_graph, hlds__hlds_pred.
-:- import_module hlds__hlds_goal, hlds__hlds_data.
-:- import_module hlds__hlds_module, check_hlds__type_util.
-:- import_module check_hlds__mode_util, parse_tree__prog_data.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- import_module hlds__passes_aux.
-:- import_module parse_tree__prog_out, libs__globals, libs__options.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
+:- import_module transform_hlds__dependency_graph.
:- import_module assoc_list, map, list, set, bool, std_util, relation, require.
:- import_module string.
Index: compiler/string_switch.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/string_switch.m,v
retrieving revision 1.40
diff -u -b -r1.40 string_switch.m
--- compiler/string_switch.m 9 Sep 2002 07:48:14 -0000 1.40
+++ compiler/string_switch.m 14 Mar 2003 10:12:21 -0000
@@ -17,10 +17,13 @@
:- interface.
+:- import_module backend_libs__code_model.
+:- import_module backend_libs__switch_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module ll_backend__code_info.
+:- import_module ll_backend__llds.
:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_data, hlds__hlds_goal.
-:- import_module ll_backend__llds, ll_backend__code_info.
-:- import_module backend_libs__switch_util, backend_libs__code_model.
:- pred string_switch__generate(cases_list, prog_var, code_model,
can_fail, hlds_goal_info, label, branch_end, branch_end, code_tree,
@@ -32,11 +35,12 @@
:- implementation.
+:- import_module backend_libs__builtin_ops.
:- import_module hlds__hlds_goal.
:- import_module hlds__hlds_llds.
-:- import_module ll_backend__code_gen, ll_backend__trace.
-:- import_module backend_libs__builtin_ops.
:- import_module libs__tree.
+:- import_module ll_backend__code_gen.
+:- import_module ll_backend__trace.
:- import_module bool, int, string, list, map, std_util, assoc_list, require.
Index: compiler/switch_detection.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/switch_detection.m,v
retrieving revision 1.99
diff -u -b -r1.99 switch_detection.m
--- compiler/switch_detection.m 27 Jan 2003 09:20:52 -0000 1.99
+++ compiler/switch_detection.m 14 Mar 2003 10:12:36 -0000
@@ -16,8 +16,11 @@
:- interface.
-:- import_module hlds__hlds_goal, hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- import_module parse_tree__prog_data.
+
:- import_module bool, io, list.
:- pred detect_switches(module_info::in, module_info::out,
@@ -48,11 +51,18 @@
:- implementation.
-:- import_module hlds__hlds_goal, hlds__hlds_data, parse_tree__prog_data.
-:- import_module hlds__instmap, check_hlds__inst_match.
-:- import_module check_hlds__modes, check_hlds__mode_util.
-:- import_module check_hlds__type_util, check_hlds__det_util.
-:- import_module hlds__passes_aux, term.
+:- import_module check_hlds__det_util.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__modes.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__instmap.
+:- import_module hlds__passes_aux.
+:- import_module parse_tree__prog_data.
+
+:- import_module term.
:- import_module char, int, assoc_list, map, set, std_util, require.
%-----------------------------------------------------------------------------%
Index: compiler/switch_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/switch_gen.m,v
retrieving revision 1.79
diff -u -b -r1.79 switch_gen.m
--- compiler/switch_gen.m 9 Sep 2002 07:48:14 -0000 1.79
+++ compiler/switch_gen.m 14 Mar 2003 10:13:01 -0000
@@ -45,9 +45,13 @@
:- interface.
-:- import_module parse_tree__prog_data, hlds__hlds_goal, hlds__hlds_data.
-:- import_module backend_libs__code_model, ll_backend__code_info.
+:- import_module backend_libs__code_model.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module ll_backend__code_info.
:- import_module ll_backend__llds.
+:- import_module parse_tree__prog_data.
+
:- import_module list.
:- pred switch_gen__generate_switch(code_model, prog_var, can_fail, list(case),
@@ -59,15 +63,21 @@
:- implementation.
-:- import_module hlds__hlds_llds.
+:- import_module backend_libs__switch_util.
:- import_module check_hlds__type_util.
-:- import_module ll_backend__dense_switch, ll_backend__string_switch.
-:- import_module ll_backend__tag_switch, ll_backend__lookup_switch.
-:- import_module ll_backend__code_gen, ll_backend__unify_gen.
-:- import_module ll_backend__code_aux, ll_backend__code_util.
+:- import_module hlds__hlds_llds.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__tree.
+:- import_module ll_backend__code_aux.
+:- import_module ll_backend__code_gen.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__dense_switch.
+:- import_module ll_backend__lookup_switch.
+:- import_module ll_backend__string_switch.
+:- import_module ll_backend__tag_switch.
:- import_module ll_backend__trace.
-:- import_module backend_libs__switch_util.
-:- import_module libs__globals, libs__options, libs__tree.
+:- import_module ll_backend__unify_gen.
:- import_module bool, int, string, map, std_util, require.
Index: compiler/switch_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/switch_util.m,v
retrieving revision 1.10
diff -u -b -r1.10 switch_util.m
--- compiler/switch_util.m 14 Jan 2003 16:42:29 -0000 1.10
+++ compiler/switch_util.m 14 Mar 2003 10:13:16 -0000
@@ -14,8 +14,13 @@
:- module backend_libs__switch_util.
:- interface.
-:- import_module parse_tree__prog_data, hlds__hlds_goal, hlds__hlds_data.
-:- import_module hlds__hlds_module, check_hlds__type_util.
+
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module parse_tree__prog_data.
+
:- import_module list, assoc_list, map, std_util.
%-----------------------------------------------------------------------------%
Index: compiler/table_gen.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/table_gen.m,v
retrieving revision 1.45
diff -u -b -r1.45 table_gen.m
--- compiler/table_gen.m 14 Mar 2003 08:10:11 -0000 1.45
+++ compiler/table_gen.m 14 Mar 2003 10:13:39 -0000
@@ -232,6 +232,7 @@
:- interface.
:- import_module hlds__hlds_module.
+
:- import_module io.
:- pred table_gen__process_module(module_info::in, module_info::out,
@@ -241,21 +242,37 @@
:- implementation.
-:- import_module parse_tree__prog_data, parse_tree__prog_out.
-:- import_module parse_tree__prog_util, parse_tree__inst.
-:- import_module hlds__hlds_module, hlds__hlds_pred.
-:- import_module hlds__hlds_goal, hlds__hlds_data.
-:- import_module hlds__instmap, hlds__passes_aux, hlds__error_util.
-:- import_module hlds__quantification, hlds__goal_util, hlds__hlds_out.
-:- import_module check_hlds__type_util, check_hlds__mode_util.
-:- import_module check_hlds__purity, check_hlds__modes, check_hlds__inst_match.
-:- import_module check_hlds__polymorphism, check_hlds__det_analysis.
-:- import_module transform_hlds__const_prop.
-:- import_module ll_backend__llds, ll_backend__code_aux.
+:- import_module backend_libs__code_model.
+:- import_module backend_libs__rtti.
+:- import_module check_hlds__det_analysis.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__modes.
+:- import_module check_hlds__polymorphism.
+:- import_module check_hlds__purity.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_out.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module hlds__passes_aux.
+:- import_module hlds__quantification.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ll_backend__code_aux.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__continuation_info.
:- import_module ll_backend__follow_code.
-:- import_module ll_backend__code_util, ll_backend__continuation_info.
-:- import_module backend_libs__code_model, backend_libs__rtti.
-:- import_module libs__globals, libs__options.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
+:- import_module transform_hlds__const_prop.
:- import_module term, varset.
:- import_module bool, int, string, list, assoc_list.
Index: compiler/tag_switch.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/tag_switch.m,v
retrieving revision 1.54
diff -u -b -r1.54 tag_switch.m
--- compiler/tag_switch.m 9 Sep 2002 07:48:16 -0000 1.54
+++ compiler/tag_switch.m 14 Mar 2003 10:13:52 -0000
@@ -14,10 +14,13 @@
:- interface.
+:- import_module backend_libs__code_model.
+:- import_module backend_libs__switch_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module ll_backend__code_info.
+:- import_module ll_backend__llds.
:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_data, hlds__hlds_goal.
-:- import_module ll_backend__llds, ll_backend__code_info.
-:- import_module backend_libs__switch_util, backend_libs__code_model.
:- import_module list.
@@ -31,12 +34,17 @@
:- implementation.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_llds.
-:- import_module check_hlds__type_util.
-:- import_module ll_backend__code_gen, ll_backend__trace.
:- import_module backend_libs__builtin_ops.
-:- import_module libs__options, libs__globals, libs__tree.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_llds.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__tree.
+:- import_module ll_backend__code_gen.
+:- import_module ll_backend__trace.
+:- import_module parse_tree__prog_data.
:- import_module bool, int, string, assoc_list, map.
:- import_module require, std_util.
Index: compiler/term_errors.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/term_errors.m,v
retrieving revision 1.17
diff -u -b -r1.17 term_errors.m
--- compiler/term_errors.m 20 Mar 2002 12:37:27 -0000 1.17
+++ compiler/term_errors.m 14 Mar 2003 10:14:06 -0000
@@ -16,7 +16,9 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, parse_tree__prog_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
:- import_module io, bag, std_util, list, assoc_list.
@@ -128,11 +130,16 @@
:- implementation.
-:- import_module hlds__hlds_out, parse_tree__prog_out, hlds__passes_aux.
:- import_module hlds__error_util.
-:- import_module term, varset.
-:- import_module parse_tree__mercury_to_mercury, transform_hlds__term_util.
-:- import_module libs__options, libs__globals.
+:- import_module hlds__hlds_out.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_out.
+:- import_module term.
+:- import_module transform_hlds__term_util.
+:- import_module varset.
:- import_module bool, int, string, map, bag, require.
Index: compiler/term_pass1.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/term_pass1.m,v
retrieving revision 1.11
diff -u -b -r1.11 term_pass1.m
--- compiler/term_pass1.m 20 Mar 2002 12:37:27 -0000 1.11
+++ compiler/term_pass1.m 14 Mar 2003 10:14:20 -0000
@@ -24,8 +24,11 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred.
-:- import_module transform_hlds__term_util, transform_hlds__term_errors.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module transform_hlds__term_errors.
+:- import_module transform_hlds__term_util.
+
:- import_module io, list, std_util.
:- type arg_size_result
@@ -49,10 +52,14 @@
:- implementation.
-:- import_module transform_hlds__term_traversal, transform_hlds__term_errors.
-:- import_module hlds__hlds_goal, hlds__hlds_data, parse_tree__prog_data.
-:- import_module check_hlds__mode_util, check_hlds__type_util.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module parse_tree__prog_data.
:- import_module transform_hlds__lp.
+:- import_module transform_hlds__term_errors.
+:- import_module transform_hlds__term_traversal.
:- import_module int, float, char, string, bool, set, bag, map.
:- import_module term, varset, require.
Index: compiler/term_pass2.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/term_pass2.m,v
retrieving revision 1.10
diff -u -b -r1.10 term_pass2.m
--- compiler/term_pass2.m 9 May 2002 16:31:08 -0000 1.10
+++ compiler/term_pass2.m 14 Mar 2003 10:14:32 -0000
@@ -17,7 +17,10 @@
:- module transform_hlds__term_pass2.
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, transform_hlds__term_util.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module transform_hlds__term_util.
+
:- import_module list.
:- pred prove_termination_in_scc(list(pred_proc_id)::in, module_info::in,
@@ -25,9 +28,12 @@
:- implementation.
-:- import_module transform_hlds__term_traversal, transform_hlds__term_errors.
-:- import_module hlds__hlds_goal, parse_tree__prog_data.
-:- import_module check_hlds__type_util, check_hlds__mode_util.
+:- import_module transform_hlds__term_traversal.
+:- import_module transform_hlds__term_errors.
+:- import_module hlds__hlds_goal.
+:- import_module parse_tree__prog_data.
+:- import_module check_hlds__type_util.
+:- import_module check_hlds__mode_util.
:- import_module std_util, bool, int, assoc_list.
:- import_module set, bag, map, term, require.
Index: compiler/term_traversal.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/term_traversal.m,v
retrieving revision 1.21
diff -u -b -r1.21 term_traversal.m
--- compiler/term_traversal.m 27 Jan 2003 09:20:53 -0000 1.21
+++ compiler/term_traversal.m 14 Mar 2003 10:14:48 -0000
@@ -20,9 +20,13 @@
:- interface.
-:- import_module transform_hlds__term_util, transform_hlds__term_errors.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_goal.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- import_module parse_tree__prog_data.
+:- import_module transform_hlds__term_errors.
+:- import_module transform_hlds__term_util.
+
:- import_module list, bag, map, std_util, set.
:- type traversal_info
@@ -97,7 +101,9 @@
:- implementation.
-:- import_module hlds__hlds_data, check_hlds__type_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+
:- import_module bool, int, require.
traverse_goal(Goal, Params, Info0, Info) :-
Index: compiler/term_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/term_util.m,v
retrieving revision 1.23
diff -u -b -r1.23 term_util.m
--- compiler/term_util.m 27 Jan 2003 09:20:53 -0000 1.23
+++ compiler/term_util.m 14 Mar 2003 10:15:03 -0000
@@ -19,9 +19,12 @@
:- interface.
-:- import_module transform_hlds__term_errors, parse_tree__prog_data.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_data.
+:- import_module hlds__hlds_data.
:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
+:- import_module transform_hlds__term_errors.
:- import_module std_util, bool, int, list, map, bag.
@@ -208,9 +211,12 @@
:- implementation.
-:- import_module check_hlds__inst_match, parse_tree__prog_out.
-:- import_module check_hlds__mode_util, check_hlds__type_util.
-:- import_module libs__globals, libs__options.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__prog_out.
:- import_module assoc_list, require.
Index: compiler/termination.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/termination.m,v
retrieving revision 1.25
diff -u -b -r1.25 termination.m
--- compiler/termination.m 28 Feb 2003 06:40:43 -0000 1.25
+++ compiler/termination.m 14 Mar 2003 10:15:36 -0000
@@ -47,10 +47,13 @@
:- interface.
-:- import_module io, bool, std_util, list.
-:- import_module parse_tree__prog_data, hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module parse_tree__prog_data.
:- import_module transform_hlds__term_util.
+:- import_module io, bool, std_util, list.
+
% Perform termination analysis on the module.
:- pred termination__pass(module_info::in, module_info::out,
@@ -85,20 +88,28 @@
:- implementation.
-:- import_module transform_hlds__term_pass1, transform_hlds__term_pass2.
-:- import_module transform_hlds__term_errors.
-:- import_module check_hlds__inst_match, hlds__passes_aux, libs__options.
-:- import_module libs__globals.
-:- import_module hlds__hlds_data, hlds__hlds_goal.
-:- import_module transform_hlds__dependency_graph, varset.
-:- import_module check_hlds__mode_util, hlds__hlds_out.
-:- import_module parse_tree__prog_out, parse_tree__prog_util.
-:- import_module parse_tree__mercury_to_mercury, check_hlds__type_util.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_out.
+:- import_module hlds__passes_aux.
:- import_module hlds__special_pred.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__mercury_to_mercury.
:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
+:- import_module transform_hlds__dependency_graph.
+:- import_module transform_hlds__term_errors.
+:- import_module transform_hlds__term_pass1.
+:- import_module transform_hlds__term_pass2.
:- import_module map, int, char, string, relation.
:- import_module require, bag, set, term.
+:- import_module varset.
%----------------------------------------------------------------------------%
Index: compiler/top_level.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/top_level.m,v
retrieving revision 1.2
diff -u -b -r1.2 top_level.m
--- compiler/top_level.m 16 Feb 2003 02:16:36 -0000 1.2
+++ compiler/top_level.m 14 Mar 2003 10:16:39 -0000
@@ -14,16 +14,22 @@
:- interface.
% the front-end phases
-:- import_module parse_tree, hlds, check_hlds, transform_hlds.
+:- import_module check_hlds.
+:- import_module hlds.
+:- import_module parse_tree.
+:- import_module transform_hlds.
% back-ends that we currently use or plan to use
-:- import_module aditi_backend, ll_backend, ml_backend.
+:- import_module aditi_backend.
+:- import_module ll_backend.
+:- import_module ml_backend.
% obsolete or incomplete back-ends
:- import_module bytecode_backend.
% misc utilities
-:- import_module libs, backend_libs.
+:- import_module backend_libs.
+:- import_module libs.
:- include_module mercury_compile.
Index: compiler/trace.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/trace.m,v
retrieving revision 1.57
diff -u -b -r1.57 trace.m
--- compiler/trace.m 9 Sep 2002 07:48:16 -0000 1.57
+++ compiler/trace.m 14 Mar 2003 10:16:58 -0000
@@ -46,10 +46,14 @@
:- interface.
-:- import_module parse_tree__prog_data.
-:- import_module hlds__hlds_goal, hlds__hlds_pred, hlds__hlds_module.
-:- import_module ll_backend__code_info, ll_backend__llds.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- import_module libs__globals.
+:- import_module ll_backend__code_info.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__prog_data.
+
:- import_module map, std_util, set.
% The kinds of external ports for which the code we generate will
@@ -213,14 +217,20 @@
:- implementation.
-:- import_module parse_tree__inst.
-:- import_module hlds__instmap, hlds__hlds_llds.
-:- import_module check_hlds__type_util.
-:- import_module check_hlds__inst_match, check_hlds__mode_util.
-:- import_module ll_backend__llds_out, ll_backend__layout_out.
-:- import_module ll_backend__continuation_info, ll_backend__code_util.
:- import_module backend_libs__code_model.
-:- import_module libs__options, libs__trace_params, libs__tree.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__hlds_llds.
+:- import_module hlds__instmap.
+:- import_module libs__options.
+:- import_module libs__trace_params.
+:- import_module libs__tree.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__continuation_info.
+:- import_module ll_backend__layout_out.
+:- import_module ll_backend__llds_out.
+:- import_module parse_tree__inst.
:- import_module list, bool, int, string, map, std_util, require, term, varset.
Index: compiler/trace_params.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/trace_params.m,v
retrieving revision 1.13
diff -u -b -r1.13 trace_params.m
--- compiler/trace_params.m 29 Sep 2002 10:30:45 -0000 1.13
+++ compiler/trace_params.m 14 Mar 2003 10:17:07 -0000
@@ -37,6 +37,7 @@
:- import_module hlds__hlds_pred.
:- import_module ll_backend__llds. % XXX for trace_port
+
:- import_module bool, std_util.
:- type trace_level.
Index: compiler/trans_opt.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/trans_opt.m,v
retrieving revision 1.20
diff -u -b -r1.20 trans_opt.m
--- compiler/trans_opt.m 24 Oct 2002 04:36:54 -0000 1.20
+++ compiler/trans_opt.m 14 Mar 2003 10:17:28 -0000
@@ -51,8 +51,11 @@
:- interface.
+:- import_module hlds__hlds_module.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_data.
+
:- import_module io, bool, list.
-:- import_module hlds__hlds_module, parse_tree__modules, parse_tree__prog_data.
:- pred trans_opt__write_optfile(module_info, io__state, io__state).
:- mode trans_opt__write_optfile(in, di, uo) is det.
@@ -70,10 +73,15 @@
:- implementation.
-:- import_module transform_hlds__intermod, hlds__hlds_pred.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__passes_aux.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ll_backend__code_util.
:- import_module parse_tree__mercury_to_mercury.
-:- import_module parse_tree__prog_io, libs__globals, ll_backend__code_util.
-:- import_module hlds__passes_aux, parse_tree__prog_out, libs__options.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_out.
+:- import_module transform_hlds__intermod.
:- import_module transform_hlds__termination.
:- import_module set, string, list, map, varset, term, std_util.
Index: compiler/transform.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/transform.m,v
retrieving revision 1.15
diff -u -b -r1.15 transform.m
--- compiler/transform.m 20 Mar 2002 12:37:29 -0000 1.15
+++ compiler/transform.m 14 Mar 2003 10:18:07 -0000
@@ -30,7 +30,10 @@
:- module transform_hlds__transform.
:- interface.
-:- import_module hlds__hlds_goal, check_hlds__mode_info.
+
+:- import_module check_hlds__mode_info.
+:- import_module hlds__hlds_goal.
+
:- import_module list.
%:- pred unfold__in_proc(pred_id, proc_id, hlds_goal_expr,
@@ -45,9 +48,15 @@
%-----------------------------------------------------------------------------%
:- implementation.
+
+:- import_module check_hlds__delay_info.
+:- import_module check_hlds__mode_util.
+:- import_module ll_backend__code_aux.
+:- import_module parse_tree__prog_data.
+
:- import_module map, set, std_util.
-:- import_module check_hlds__mode_util, check_hlds__delay_info, term, require.
-:- import_module varset, ll_backend__code_aux, parse_tree__prog_data.
+:- import_module term, require.
+:- import_module varset.
:- import_module hlds__instmap.
%-----------------------------------------------------------------------------%
Index: compiler/transform_hlds.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/transform_hlds.m,v
retrieving revision 1.4
diff -u -b -r1.4 transform_hlds.m
--- compiler/transform_hlds.m 2 Jan 2003 06:53:56 -0000 1.4
+++ compiler/transform_hlds.m 14 Mar 2003 10:18:47 -0000
@@ -25,7 +25,10 @@
:- include_module (lambda).
:- include_module termination.
- :- include_module term_pass1, term_pass2, term_traversal, term_errors.
+ :- include_module term_pass1.
+ :- include_module term_pass2.
+ :- include_module term_traversal.
+ :- include_module term_errors.
:- include_module term_util.
:- include_module lp. % this could alternatively go in the `libs' module
@@ -33,7 +36,11 @@
:- include_module higher_order.
:- include_module inlining.
:- include_module deforest.
- :- include_module constraint, pd_cost, pd_debug, pd_info, pd_term.
+ :- include_module constraint.
+ :- include_module pd_cost.
+ :- include_module pd_debug.
+ :- include_module pd_info.
+ :- include_module pd_term.
:- include_module pd_util.
:- include_module delay_construct.
:- include_module unused_args.
Index: compiler/tree.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/tree.m,v
retrieving revision 1.15
diff -u -b -r1.15 tree.m
--- compiler/tree.m 20 Mar 2002 12:37:30 -0000 1.15
+++ compiler/tree.m 14 Mar 2003 10:19:04 -0000
@@ -18,7 +18,9 @@
%-----------------------------------------------------------------------------%
:- interface.
+
:- import_module list.
+
:- type tree(T) ---> empty
; node(T)
; tree(tree(T), tree(T)).
@@ -81,6 +83,5 @@
tree__map(_F, empty) = empty.
tree__map(F, node(T)) = node(F(T)).
tree__map(F, tree(L, R)) = tree(tree__map(F, L), tree__map(F, R)).
-
%-----------------------------------------------------------------------------%
Index: compiler/type_ctor_info.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/type_ctor_info.m,v
retrieving revision 1.36
diff -u -b -r1.36 type_ctor_info.m
--- compiler/type_ctor_info.m 14 Mar 2003 08:10:12 -0000 1.36
+++ compiler/type_ctor_info.m 14 Mar 2003 10:19:21 -0000
@@ -35,7 +35,9 @@
:- interface.
-:- import_module hlds__hlds_module, backend_libs__rtti.
+:- import_module backend_libs__rtti.
+:- import_module hlds__hlds_module.
+
:- import_module list.
:- pred type_ctor_info__generate_hlds(module_info::in, module_info::out)
@@ -57,14 +59,24 @@
:- implementation.
-:- import_module backend_libs__rtti, backend_libs__pseudo_type_info.
-:- import_module hlds__hlds_data, hlds__hlds_pred, hlds__hlds_out.
-:- import_module hlds__make_tags, parse_tree__prog_data.
-:- import_module parse_tree__prog_util, parse_tree__prog_out.
-:- import_module ll_backend__code_util, hlds__special_pred.
-:- import_module hlds__hlds_code_util, hlds__special_pred.
-:- import_module check_hlds__type_util, libs__globals, libs__options.
-:- import_module backend_libs__builtin_ops, hlds__error_util.
+:- import_module backend_libs__builtin_ops.
+:- import_module backend_libs__pseudo_type_info.
+:- import_module backend_libs__rtti.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module hlds__hlds_code_util.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_out.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__make_tags.
+:- import_module hlds__special_pred.
+:- import_module hlds__special_pred.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module ll_backend__code_util.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
:- import_module bool, string, int, map, std_util, assoc_list, require.
:- import_module set, term.
Index: compiler/type_util.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/type_util.m,v
retrieving revision 1.115
diff -u -b -r1.115 type_util.m
--- compiler/type_util.m 12 Feb 2003 22:58:12 -0000 1.115
+++ compiler/type_util.m 14 Mar 2003 10:19:40 -0000
@@ -18,8 +18,11 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_data.
-:- import_module parse_tree__prog_data, libs__globals.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module libs__globals.
+:- import_module parse_tree__prog_data.
:- import_module term.
:- import_module bool, std_util, list, map.
@@ -497,11 +500,14 @@
:- implementation.
-:- import_module parse_tree__prog_io, parse_tree__prog_io_goal.
:- import_module backend_libs__foreign.
-:- import_module parse_tree__prog_util.
:- import_module check_hlds__purity.
-:- import_module libs__options, libs__globals.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_io_goal.
+:- import_module parse_tree__prog_util.
+
:- import_module bool, char, int, string.
:- import_module assoc_list, require, varset.
Index: compiler/typecheck.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/typecheck.m,v
retrieving revision 1.332
diff -u -b -r1.332 typecheck.m
--- compiler/typecheck.m 13 Mar 2003 11:53:35 -0000 1.332
+++ compiler/typecheck.m 14 Mar 2003 10:20:05 -0000
@@ -102,8 +102,11 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_data.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__hlds_data.
:- import_module parse_tree__prog_data.
+
:- import_module bool, io, list, map.
% typecheck(Module0, Module, FoundError,
@@ -154,15 +157,26 @@
:- implementation.
-:- import_module hlds__hlds_goal, hlds__goal_util, parse_tree__prog_util.
-:- import_module check_hlds__type_util, parse_tree__modules.
-:- import_module parse_tree__prog_io, parse_tree__prog_io_util.
-:- import_module parse_tree__prog_out, hlds__hlds_out, hlds__error_util.
-:- import_module parse_tree__mercury_to_mercury, check_hlds__mode_util.
-:- import_module libs__options, getopt, libs__globals.
-:- import_module hlds__passes_aux, check_hlds__clause_to_proc.
-:- import_module hlds__special_pred, check_hlds__inst_match.
+:- import_module check_hlds__clause_to_proc.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__type_util.
+:- import_module hlds__error_util.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_out.
+:- import_module hlds__passes_aux.
+:- import_module hlds__special_pred.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_io.
+:- import_module parse_tree__prog_io_util.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
+:- import_module getopt.
:- import_module int, set, string, require, multi_map.
:- import_module assoc_list, std_util, term, varset, term_io.
Index: compiler/unify_proc.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/unify_proc.m,v
retrieving revision 1.116
diff -u -b -r1.116 unify_proc.m
--- compiler/unify_proc.m 28 Feb 2003 00:21:38 -0000 1.116
+++ compiler/unify_proc.m 14 Mar 2003 10:21:29 -0000
@@ -46,10 +46,15 @@
:- module check_hlds__unify_proc.
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_goal.
+
+:- import_module check_hlds__mode_info.
:- import_module hlds__hlds_data.
-:- import_module check_hlds__mode_info, parse_tree__prog_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
:- import_module hlds__special_pred.
+:- import_module parse_tree__prog_data.
+
:- import_module bool, std_util, io, list.
:- type proc_requests.
@@ -124,23 +129,36 @@
:- implementation.
-:- import_module libs__globals, libs__options.
-:- import_module ll_backend__code_util, ll_backend__code_info.
+:- import_module check_hlds__clause_to_proc.
+:- import_module check_hlds__cse_detection.
+:- import_module check_hlds__det_analysis.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__modes.
+:- import_module check_hlds__polymorphism.
+:- import_module check_hlds__post_typecheck.
+:- import_module check_hlds__switch_detection.
:- import_module check_hlds__type_util.
-:- import_module parse_tree__mercury_to_mercury, hlds__hlds_out.
-:- import_module hlds__make_hlds, check_hlds__polymorphism.
-:- import_module check_hlds__post_typecheck, parse_tree__prog_util.
+:- import_module check_hlds__unique_modes.
+:- import_module hlds__goal_util.
+:- import_module hlds__hlds_out.
+:- import_module hlds__instmap.
+:- import_module hlds__make_hlds.
+:- import_module hlds__quantification.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module libs__tree.
+:- import_module ll_backend__code_info.
+:- import_module ll_backend__code_util.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__mercury_to_mercury.
:- import_module parse_tree__prog_out.
-:- import_module hlds__quantification, check_hlds__clause_to_proc, term.
-:- import_module varset.
-:- import_module check_hlds__modes, check_hlds__mode_util.
-:- import_module check_hlds__inst_match, hlds__instmap, (parse_tree__inst).
-:- import_module check_hlds__switch_detection, check_hlds__cse_detection.
-:- import_module check_hlds__det_analysis, check_hlds__unique_modes.
+:- import_module parse_tree__prog_util.
:- import_module recompilation.
-:- import_module hlds__goal_util.
-:- import_module libs__tree, map, set, queue, int, string, require, assoc_list.
+:- import_module term.
+:- import_module varset.
+:- import_module map, set, queue, int, string, require, assoc_list.
% We keep track of all the complicated unification procs we need
% by storing them in the proc_requests structure.
@@ -197,7 +215,10 @@
%-----------------------------------------------------------------------------%
unify_proc__lookup_mode_num(ModuleInfo, TypeCtor, UniMode, Det, Num) :-
- ( unify_proc__search_mode_num(ModuleInfo, TypeCtor, UniMode, Det, Num1) ->
+ (
+ unify_proc__search_mode_num(ModuleInfo, TypeCtor, UniMode,
+ Det, Num1)
+ ->
Num = Num1
;
error("unify_proc.m: unify_proc__search_num failed")
Index: compiler/unique_modes.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/unique_modes.m,v
retrieving revision 1.75
diff -u -b -r1.75 unique_modes.m
--- compiler/unique_modes.m 27 Jan 2003 09:20:53 -0000 1.75
+++ compiler/unique_modes.m 14 Mar 2003 10:21:51 -0000
@@ -35,8 +35,12 @@
:- module check_hlds__unique_modes.
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred, hlds__hlds_goal.
+
:- import_module check_hlds__mode_info.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+
:- import_module io, bool.
% check every predicate in a module
@@ -58,15 +62,25 @@
:- implementation.
-:- import_module hlds__hlds_data, check_hlds__mode_debug.
-:- import_module check_hlds__modecheck_unify, check_hlds__modecheck_call.
-:- import_module check_hlds__mode_util, parse_tree__prog_out, hlds__hlds_out.
-:- import_module parse_tree__mercury_to_mercury, hlds__passes_aux.
-:- import_module check_hlds__modes, parse_tree__prog_data.
-:- import_module check_hlds__mode_errors, ll_backend__llds.
-:- import_module check_hlds__unify_proc.
-:- import_module (parse_tree__inst), hlds__instmap, check_hlds__inst_match.
+:- import_module check_hlds__inst_match.
:- import_module check_hlds__inst_util.
+:- import_module check_hlds__mode_debug.
+:- import_module check_hlds__mode_errors.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__modecheck_call.
+:- import_module check_hlds__modecheck_unify.
+:- import_module check_hlds__modes.
+:- import_module check_hlds__unify_proc.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_out.
+:- import_module hlds__instmap.
+:- import_module hlds__passes_aux.
+:- import_module ll_backend__llds.
+:- import_module parse_tree__inst.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
+
:- import_module term, varset.
:- import_module assoc_list, bag, int, list, map.
:- import_module require, set, std_util, string.
Index: compiler/unneeded_code.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/unneeded_code.m,v
retrieving revision 1.12
diff -u -b -r1.12 unneeded_code.m
--- compiler/unneeded_code.m 28 Mar 2002 03:43:46 -0000 1.12
+++ compiler/unneeded_code.m 14 Mar 2003 10:22:03 -0000
@@ -57,7 +57,9 @@
:- interface.
-:- import_module hlds__hlds_module, hlds__hlds_pred.
+:- import_module hlds__hlds_module.
+:- import_module hlds__hlds_pred.
+
:- import_module io.
:- pred unneeded_code__process_proc_msg(pred_id::in, proc_id::in,
@@ -69,13 +71,20 @@
:- implementation.
-:- import_module parse_tree__prog_data, parse_tree__prog_data.
-:- import_module hlds__hlds_goal, hlds__instmap, hlds__quantification.
-:- import_module hlds__goal_form, hlds__passes_aux, hlds__hlds_out.
-:- import_module check_hlds__inst_match, check_hlds__mode_util.
:- import_module check_hlds__goal_path.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module hlds__goal_form.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_out.
+:- import_module hlds__instmap.
+:- import_module hlds__passes_aux.
+:- import_module hlds__quantification.
+:- import_module libs__globals.
+:- import_module libs__options.
:- import_module ll_backend__code_aux.
-:- import_module libs__globals, libs__options.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_data.
:- import_module bool, int, list, assoc_list, map, set, std_util, require.
Index: compiler/unused_args.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/unused_args.m,v
retrieving revision 1.82
diff -u -b -r1.82 unused_args.m
--- compiler/unused_args.m 28 Feb 2003 06:40:43 -0000 1.82
+++ compiler/unused_args.m 14 Mar 2003 10:22:19 -0000
@@ -43,8 +43,9 @@
%-------------------------------------------------------------------------------
:- interface.
-:- import_module hlds__hlds_module.
:- import_module analysis.
+:- import_module hlds__hlds_module.
+
:- import_module io.
:- pred unused_args__process_module(module_info::in, module_info::out,
@@ -63,18 +64,28 @@
%-------------------------------------------------------------------------------
:- implementation.
-:- import_module parse_tree__mercury_to_mercury, parse_tree__modules.
-:- import_module parse_tree__prog_data, parse_tree__prog_out.
-:- import_module parse_tree__prog_util.
-:- import_module hlds__hlds_pred, hlds__hlds_goal, hlds__hlds_data.
-:- import_module hlds__hlds_out, hlds__instmap, hlds__make_hlds.
-:- import_module hlds__quantification, hlds__special_pred.
-:- import_module hlds__passes_aux.
+:- import_module check_hlds__inst_match.
+:- import_module check_hlds__mode_util.
+:- import_module check_hlds__polymorphism.
+:- import_module check_hlds__type_util.
:- import_module hlds__goal_util.
-:- import_module check_hlds__type_util, check_hlds__mode_util.
-:- import_module check_hlds__inst_match, check_hlds__polymorphism.
+:- import_module hlds__hlds_data.
+:- import_module hlds__hlds_goal.
+:- import_module hlds__hlds_out.
+:- import_module hlds__hlds_pred.
+:- import_module hlds__instmap.
+:- import_module hlds__make_hlds.
+:- import_module hlds__passes_aux.
+:- import_module hlds__quantification.
+:- import_module hlds__special_pred.
+:- import_module libs__globals.
+:- import_module libs__options.
+:- import_module parse_tree__mercury_to_mercury.
+:- import_module parse_tree__modules.
+:- import_module parse_tree__prog_data.
+:- import_module parse_tree__prog_out.
+:- import_module parse_tree__prog_util.
:- import_module transform_hlds__mmc_analysis.
-:- import_module libs__options, libs__globals.
:- import_module bool, int, char, string, list, assoc_list, set, map.
:- import_module std_util, require.
Index: compiler/use_local_vars.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/use_local_vars.m,v
retrieving revision 1.4
diff -u -b -r1.4 use_local_vars.m
--- compiler/use_local_vars.m 14 Mar 2003 08:10:12 -0000 1.4
+++ compiler/use_local_vars.m 14 Mar 2003 10:22:26 -0000
@@ -63,6 +63,7 @@
:- import_module backend_libs__proc_label.
:- import_module ll_backend__llds.
+
:- import_module list, counter.
:- pred use_local_vars__main(list(instruction)::in, list(instruction)::out,
Index: compiler/var_locn.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/var_locn.m,v
retrieving revision 1.6
diff -u -b -r1.6 var_locn.m
--- compiler/var_locn.m 28 Mar 2002 03:43:47 -0000 1.6
+++ compiler/var_locn.m 14 Mar 2003 10:22:41 -0000
@@ -323,8 +323,11 @@
:- implementation.
-:- import_module ll_backend__code_util, ll_backend__exprn_aux.
-:- import_module libs__options, libs__tree.
+:- import_module libs__options.
+:- import_module libs__tree.
+:- import_module ll_backend__code_util.
+:- import_module ll_backend__exprn_aux.
+
:- import_module int, string, bag, require, getopt, varset, term.
:- type dead_or_alive ---> dead ; alive.
Index: compiler/wrap_blocks.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/wrap_blocks.m,v
retrieving revision 1.4
diff -u -b -r1.4 wrap_blocks.m
--- compiler/wrap_blocks.m 20 Mar 2002 12:37:37 -0000 1.4
+++ compiler/wrap_blocks.m 14 Mar 2003 10:22:46 -0000
@@ -22,6 +22,7 @@
:- interface.
:- import_module ll_backend__llds.
+
:- import_module list.
:- pred wrap_blocks(list(instruction)::in, list(instruction)::out)
@@ -30,6 +31,7 @@
:- implementation.
:- import_module ll_backend__opt_util.
+
:- import_module bool, int, std_util, require.
wrap_blocks(Instrs0, Instrs) :-
cvs diff: Diffing compiler/notes
cvs diff: Diffing debian
cvs diff: Diffing deep_profiler
cvs diff: Diffing deep_profiler/notes
cvs diff: Diffing doc
cvs diff: Diffing extras
cvs diff: Diffing extras/aditi
cvs diff: Diffing extras/cgi
cvs diff: Diffing extras/complex_numbers
cvs diff: Diffing extras/complex_numbers/samples
cvs diff: Diffing extras/complex_numbers/tests
cvs diff: Diffing extras/concurrency
cvs diff: Diffing extras/curs
cvs diff: Diffing extras/curs/samples
cvs diff: Diffing extras/curses
cvs diff: Diffing extras/curses/sample
cvs diff: Diffing extras/dynamic_linking
cvs diff: Diffing extras/graphics
cvs diff: Diffing extras/graphics/mercury_opengl
cvs diff: Diffing extras/graphics/mercury_tcltk
cvs diff: Diffing extras/graphics/samples
cvs diff: Diffing extras/graphics/samples/calc
cvs diff: Diffing extras/graphics/samples/maze
cvs diff: Diffing extras/graphics/samples/pent
cvs diff: Diffing extras/lazy_evaluation
cvs diff: Diffing extras/lex
cvs diff: Diffing extras/lex/samples
cvs diff: Diffing extras/lex/tests
cvs diff: Diffing extras/logged_output
cvs diff: Diffing extras/moose
cvs diff: Diffing extras/moose/samples
cvs diff: Diffing extras/morphine
cvs diff: Diffing extras/morphine/non-regression-tests
cvs diff: Diffing extras/morphine/scripts
cvs diff: Diffing extras/morphine/source
cvs diff: Diffing extras/odbc
cvs diff: Diffing extras/posix
cvs diff: Diffing extras/quickcheck
cvs diff: Diffing extras/quickcheck/tutes
cvs diff: Diffing extras/references
cvs diff: Diffing extras/references/samples
cvs diff: Diffing extras/references/tests
cvs diff: Diffing extras/stream
cvs diff: Diffing extras/trailed_update
cvs diff: Diffing extras/trailed_update/samples
cvs diff: Diffing extras/trailed_update/tests
cvs diff: Diffing extras/xml
cvs diff: Diffing extras/xml/samples
cvs diff: Diffing java
cvs diff: Diffing java/library
cvs diff: Diffing java/runtime
cvs diff: Diffing library
Index: library/parser.m
===================================================================
RCS file: /home/mercury1/repository/mercury/library/parser.m,v
retrieving revision 1.40
diff -u -b -r1.40 parser.m
--- library/parser.m 15 Feb 2003 21:56:53 -0000 1.40
+++ library/parser.m 13 Mar 2003 12:40:34 -0000
@@ -781,16 +781,60 @@
:- type parser__state(Ops, T) % <= op_table(Ops)
---> parser__state(
- string, % the name of the stream being parsed
- Ops, % the current set of operators
- varset(T), % the names of the variables in the
+ stream_name :: string,
+ % the name of the stream being parsed
+ ops_table :: Ops,
+ % the current set of operators
+ varset :: varset(T),
+ % the names of the variables in the
% term being parsed
- token_list, % the remaining tokens
- map(string, var(T))
+ tokens_left :: token_list,
+ % the remaining tokens
+ var_names :: map(string, var(T))
% a map from variable name to variable
% so we know when to make a fresh var
).
+:- func parser_state_get_stream_name(parser__state(Ops, T)) = string.
+:- func parser_state_get_ops_table(parser__state(Ops, T)) = Ops.
+:- func parser_state_get_varset(parser__state(Ops, T)) = varset(T).
+:- func parser_state_get_tokens_left(parser__state(Ops, T)) = token_list.
+:- func parser_state_get_var_names(parser__state(Ops, T)) =
+ map(string, var(T)).
+
+:- func parser_state_set_varset(parser__state(Ops, T), varset(T))
+ = parser__state(Ops, T).
+:- func parser_state_set_tokens_left(parser__state(Ops, T), token_list)
+ = parser__state(Ops, T).
+:- func parser_state_set_var_names(parser__state(Ops, T), map(string, var(T)))
+ = parser__state(Ops, T).
+
+% If you want profiling to tell you the frequencies of these operations,
+% change the inline pragmas to no_inline pragmas.
+
+:- pragma inline(parser_state_get_stream_name/1).
+:- pragma inline(parser_state_get_ops_table/1).
+:- pragma inline(parser_state_get_varset/1).
+:- pragma inline(parser_state_get_tokens_left/1).
+:- pragma inline(parser_state_get_var_names/1).
+
+:- pragma inline(parser_state_set_varset/2).
+:- pragma inline(parser_state_set_tokens_left/2).
+:- pragma inline(parser_state_set_var_names/2).
+
+parser_state_get_stream_name(ParserState) = ParserState ^ stream_name.
+parser_state_get_ops_table(ParserState) = ParserState ^ ops_table.
+parser_state_get_varset(ParserState) = ParserState ^ varset.
+parser_state_get_tokens_left(ParserState) = ParserState ^ tokens_left.
+parser_state_get_var_names(ParserState) = ParserState ^ var_names.
+
+parser_state_set_varset(ParserState0, VarSet) =
+ ParserState0 ^ varset := VarSet.
+parser_state_set_tokens_left(ParserState0, Tokens) =
+ ParserState0 ^ tokens_left := Tokens.
+parser_state_set_var_names(ParserState0, Names) =
+ ParserState0 ^ var_names := Names.
+
%-----------------------------------------------------------------------------%
% We encountered an error. See if the next token
@@ -840,7 +884,7 @@
:- mode parser__error(in, out, in, out) is det.
parser__error(Message, error(Message, Tokens), ParserState, ParserState) :-
- ParserState = parser__state(_, _, _, Tokens, _).
+ Tokens = parser_state_get_tokens_left(ParserState).
%-----------------------------------------------------------------------------%
@@ -882,8 +926,9 @@
:- pred parser__final_state(parser__state(Ops, T), varset(T), token_list).
:- mode parser__final_state(in, out, out) is det.
-parser__final_state(parser__state(_FileName, _OpTable, VarSet, TokenList,
- _Names), VarSet, TokenList).
+parser__final_state(ParserState, VarSet, TokenList) :-
+ VarSet = parser_state_get_varset(ParserState),
+ TokenList = parser_state_get_tokens_left(ParserState).
%-----------------------------------------------------------------------------%
@@ -896,20 +941,22 @@
:- pred parser__get_token(token, token_context,
parser__state(Ops, T), parser__state(Ops, T)).
:- mode parser__get_token(out, out, in, out) is semidet.
-:- mode parser__get_token(in, in, out, in) is det.
+% :- mode parser__get_token(in, in, out, in) is det.
-parser__get_token(Token, Context,
- parser__state(FileName, OpTable, VarSet, Tokens0, Names),
- parser__state(FileName, OpTable, VarSet, Tokens, Names)) :-
- Tokens0 = token_cons(Token, Context, Tokens).
+parser__get_token(Token, Context, ParserState0, ParserState) :-
+ Tokens0 = parser_state_get_tokens_left(ParserState0),
+ Tokens0 = token_cons(Token, Context, Tokens),
+ ParserState = parser_state_set_tokens_left(ParserState0, Tokens).
:- pred parser__unget_token(token, token_context,
parser__state(Ops, T), parser__state(Ops, T)).
:- mode parser__unget_token(in, in, in, out) is det.
-:- mode parser__unget_token(out, out, out, in) is semidet.
+% :- mode parser__unget_token(out, out, out, in) is semidet.
-parser__unget_token(Token, Context, ParseState0, ParseState) :-
- parser__get_token(Token, Context, ParseState, ParseState0).
+parser__unget_token(Token, Context, ParserState0, ParserState) :-
+ Tokens0 = parser_state_get_tokens_left(ParserState0),
+ Tokens = token_cons(Token, Context, Tokens0),
+ ParserState = parser_state_set_tokens_left(ParserState0, Tokens).
:- pred parser__peek_token(token, parser__state(Ops, T), parser__state(Ops, T)).
:- mode parser__peek_token(out, in, out) is semidet.
@@ -921,9 +968,9 @@
parser__state(Ops, T), parser__state(Ops, T)).
:- mode parser__peek_token(out, out, in, out) is semidet.
-parser__peek_token(Token, Context) -->
- =(parser__state(_, _, _, Tokens, _)),
- { Tokens = token_cons(Token, Context, _) }.
+parser__peek_token(Token, Context, ParserState, ParserState) :-
+ Tokens = parser_state_get_tokens_left(ParserState),
+ Tokens = token_cons(Token, Context, _).
%-----------------------------------------------------------------------------%
@@ -931,27 +978,33 @@
parser__state(Ops, T)).
:- mode parser__add_var(in, out, in, out) is det.
-parser__add_var(VarName, Var,
- parser__state(FileName, OpTable, VarSet0, Tokens, Names0),
- parser__state(FileName, OpTable, VarSet, Tokens, Names)) :-
+parser__add_var(VarName, Var, ParserState0, ParserState) :-
( VarName = "_" ->
+ VarSet0 = parser_state_get_varset(ParserState0),
varset__new_var(VarSet0, Var, VarSet),
- Names = Names0
- ; map__search(Names0, VarName, Var0) ->
+ ParserState = parser_state_set_varset(ParserState0, VarSet)
+ ;
+ Names0 = parser_state_get_var_names(ParserState0),
+ ( map__search(Names0, VarName, Var0) ->
Var = Var0,
- VarSet = VarSet0,
- Names = Names0
+ ParserState = ParserState0
;
+ VarSet0 = parser_state_get_varset(ParserState0),
varset__new_named_var(VarSet0, VarName, Var, VarSet),
- map__det_insert(Names0, VarName, Var, Names)
+ map__det_insert(Names0, VarName, Var, Names),
+ ParserState1 = parser_state_set_varset(ParserState0,
+ VarSet),
+ ParserState = parser_state_set_var_names(ParserState1,
+ Names)
+ )
).
:- pred parser__get_ops_table(Ops, parser__state(Ops, T),
parser__state(Ops, T)) <= op_table(Ops).
:- mode parser__get_ops_table(out, in, out) is det.
-parser__get_ops_table(OpTable) -->
- =(parser__state(_, OpTable, _, _, _)).
+parser__get_ops_table(OpTable, ParserState, ParserState) :-
+ OpTable = parser_state_get_ops_table(ParserState).
%-----------------------------------------------------------------------------%
%-----------------------------------------------------------------------------%
@@ -975,9 +1028,10 @@
parser__state(Ops, T), parser__state(Ops, T)).
:- mode parser__get_term_context(in, out, in, out) is det.
-parser__get_term_context(TokenContext, TermContext) -->
- =(parser__state(FileName, _Ops, _VarSet, _Tokens, _Names)),
- { term__context_init(FileName, TokenContext, TermContext) }.
+parser__get_term_context(TokenContext, TermContext, ParserState, ParserState)
+ :-
+ FileName = parser_state_get_stream_name(ParserState),
+ term__context_init(FileName, TokenContext, TermContext).
%-----------------------------------------------------------------------------%
%-----------------------------------------------------------------------------%
cvs diff: Diffing profiler
cvs diff: Diffing robdd
cvs diff: Diffing runtime
cvs diff: Diffing runtime/GETOPT
cvs diff: Diffing runtime/machdeps
cvs diff: Diffing samples
cvs diff: Diffing samples/c_interface
cvs diff: Diffing samples/c_interface/c_calls_mercury
cvs diff: Diffing samples/c_interface/cplusplus_calls_mercury
cvs diff: Diffing samples/c_interface/mercury_calls_c
cvs diff: Diffing samples/c_interface/mercury_calls_cplusplus
cvs diff: Diffing samples/c_interface/mercury_calls_fortran
cvs diff: Diffing samples/c_interface/simpler_c_calls_mercury
cvs diff: Diffing samples/c_interface/simpler_cplusplus_calls_mercury
cvs diff: Diffing samples/diff
cvs diff: Diffing samples/muz
cvs diff: Diffing samples/rot13
cvs diff: Diffing samples/solutions
cvs diff: Diffing samples/tests
cvs diff: Diffing samples/tests/c_interface
cvs diff: Diffing samples/tests/c_interface/c_calls_mercury
cvs diff: Diffing samples/tests/c_interface/cplusplus_calls_mercury
cvs diff: Diffing samples/tests/c_interface/mercury_calls_c
cvs diff: Diffing samples/tests/c_interface/mercury_calls_cplusplus
cvs diff: Diffing samples/tests/c_interface/mercury_calls_fortran
cvs diff: Diffing samples/tests/c_interface/simpler_c_calls_mercury
cvs diff: Diffing samples/tests/c_interface/simpler_cplusplus_calls_mercury
cvs diff: Diffing samples/tests/diff
cvs diff: Diffing samples/tests/muz
cvs diff: Diffing samples/tests/rot13
cvs diff: Diffing samples/tests/solutions
cvs diff: Diffing samples/tests/toplevel
cvs diff: Diffing scripts
cvs diff: Diffing tests
cvs diff: Diffing tests/benchmarks
cvs diff: Diffing tests/debugger
cvs diff: Diffing tests/debugger/declarative
cvs diff: Diffing tests/dppd
cvs diff: Diffing tests/general
cvs diff: Diffing tests/general/accumulator
cvs diff: Diffing tests/general/string_format
cvs diff: Diffing tests/general/structure_reuse
cvs diff: Diffing tests/grade_subdirs
cvs diff: Diffing tests/hard_coded
cvs diff: Diffing tests/hard_coded/exceptions
cvs diff: Diffing tests/hard_coded/purity
cvs diff: Diffing tests/hard_coded/sub-modules
cvs diff: Diffing tests/hard_coded/typeclasses
cvs diff: Diffing tests/invalid
cvs diff: Diffing tests/invalid/purity
cvs diff: Diffing tests/misc_tests
cvs diff: Diffing tests/mmc_make
cvs diff: Diffing tests/mmc_make/lib
cvs diff: Diffing tests/recompilation
cvs diff: Diffing tests/tabling
cvs diff: Diffing tests/term
cvs diff: Diffing tests/valid
cvs diff: Diffing tests/warnings
cvs diff: Diffing tools
cvs diff: Diffing trace
cvs diff: Diffing util
cvs diff: Diffing vim
cvs diff: Diffing vim/after
cvs diff: Diffing vim/ftplugin
cvs diff: Diffing vim/syntax
--------------------------------------------------------------------------
mercury-reviews mailing list
post: mercury-reviews at cs.mu.oz.au
administrative address: owner-mercury-reviews at cs.mu.oz.au
unsubscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: unsubscribe
subscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------
More information about the reviews
mailing list