mirror of
https://github.com/Mercury-Language/mercury.git
synced 2025-12-15 22:03:26 +00:00
Estimated hours taken: 100
Branches: main
Make definitions of abstract types available when generating
code for importing modules. This is necessary for the .NET
back-end, and for `:- pragma export' on the C back-end.
compiler/prog_data.m:
compiler/modules.m:
compiler/make.dependencies.m:
compiler/recompilation.version.m:
Handle implementation sections in interface files.
There is a new pseudo-declaration `abstract_imported'
which is applied to items from the implementation
section of an interface file. `abstract_imported'
items may not be used in the error checking passes
for the curent module.
compiler/equiv_type_hlds.m:
compiler/notes/compiler_design.html:
New file.
Go over the HLDS expanding all types fully after
semantic checking has been run.
compiler/mercury_compile.m:
Add the new pass.
Don't write the `.opt' file if there are any errors.
compiler/instmap.m:
Add a predicate instmap_delta_map_foldl to apply
a procedure to all insts in an instmap.
compiler/equiv_type.m:
Export predicates for use by equiv_type_hlds.m
Reorder arguments so state variables and higher-order
programming can be used.
compiler/prog_data.m:
compiler/prog_io_pragma.m:
compiler/make_hlds.m:
compiler/mercury_to_mercury.m:
Handle `:- pragma foreign_type' as a form of type
declaration rather than a pragma.
compiler/hlds_data.m:
compiler/*.m:
Add a field to the type_info_cell_constructor cons_id
to identify the type_ctor, which is needed by
equiv_type_hlds.m.
compiler/module_qual.m:
Donn't allow items from the implementation section of
interface files to match items in the current module.
compiler/*.m:
tests/*/*.m:
Add missing imports which only became apparent with
the bug fixes above.
Remove unnecessary imports which only became apparent with
the bug fixes above.
tests/hard_coded/Mmakefile:
tests/hard_coded/export_test2.{m,exp}:
Test case.
tests/invalid/Mmakefile:
tests/invalid/missing_interface_import2.{m,err_exp}:
Test case.
73 lines
2.2 KiB
Mathematica
73 lines
2.2 KiB
Mathematica
%-----------------------------------------------------------------------------%
|
|
% Copyright (C) 2002-2003 The University of Melbourne.
|
|
% This file may only be copied under the terms of the GNU General
|
|
% Public License - see the file COPYING in the Mercury distribution.
|
|
%-----------------------------------------------------------------------------%
|
|
%
|
|
% transform_hlds: High-level transformations
|
|
% that are independent of the choice of back-end
|
|
% (the "middle" HLDS pass).
|
|
%
|
|
|
|
:- module transform_hlds.
|
|
:- interface.
|
|
:- import_module check_hlds. % is this needed?
|
|
:- import_module hlds, parse_tree, libs.
|
|
|
|
%-----------------------------------------------------------------------------%
|
|
|
|
:- include_module intermod, trans_opt.
|
|
|
|
:- include_module dependency_graph. % XXX imports llds (for profiling labels)
|
|
|
|
:- include_module equiv_type_hlds.
|
|
|
|
:- include_module table_gen.
|
|
|
|
:- include_module (lambda).
|
|
|
|
:- include_module termination.
|
|
:- include_module term_pass1.
|
|
:- include_module term_pass2.
|
|
:- include_module term_traversal.
|
|
:- include_module term_errors.
|
|
:- include_module term_norm.
|
|
:- include_module term_util.
|
|
:- include_module lp. % this could alternatively go in the `libs' module
|
|
|
|
% Optimizations (HLDS -> HLDS)
|
|
:- include_module higher_order.
|
|
:- include_module inlining.
|
|
:- include_module deforest.
|
|
:- 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.
|
|
:- include_module unneeded_code.
|
|
:- include_module accumulator.
|
|
:- include_module goal_store.
|
|
:- include_module dead_proc_elim.
|
|
:- include_module const_prop.
|
|
:- include_module loop_inv.
|
|
:- include_module size_prof.
|
|
|
|
:- include_module mmc_analysis.
|
|
|
|
% XXX The following modules are all currently unused.
|
|
:- include_module transform.
|
|
:- include_module lco.
|
|
|
|
%-----------------------------------------------------------------------------%
|
|
|
|
:- implementation.
|
|
:- import_module ll_backend. % XXX for code_util, code_aux
|
|
:- import_module backend_libs. % XXX for rtti
|
|
|
|
:- end_module transform_hlds.
|
|
|
|
%-----------------------------------------------------------------------------%
|