[m-rev.] for review: more invariants for includes/imports/uses in .int[03]
    Julien Fischer 
    jfischer at opturion.com
       
    Fri Sep  2 12:50:25 AEST 2022
    
    
  
On Thu, 1 Sep 2022, Zoltan Somogyi wrote:
> A similar change to .int/.int2 files is next, but it should also include
> a fix for Mantis bug 563.
...
> Tighten representation of include/import/use decls.
...
> diff --git a/compiler/prog_item.m b/compiler/prog_item.m
> index ea01f68c9..c710140b3 100644
> --- a/compiler/prog_item.m
> +++ b/compiler/prog_item.m
> @@ -93,6 +93,29 @@
>  :- type module_name_context == map(module_name, prog_context).
>  :- type module_names_contexts == one_or_more_map(module_name, prog_context).
> 
> +    % Maps from module names to the includes, imports or uses
> +    % in the named section. The code creating these maps will have
> +    % detected and diagnosed any duplicate entries of the same kind
> +    % of declaration for the same module in the same section.
> +    % However, unlike include_module_maps or import_and_or_use_maps,
> +    % which summarize the information in the first two of the maps below
> +    % (for include_module_map) or the last foir (for import_and_or_use_map),
s/foir/four/
> +    % these maps may contain redundant entries as long as they are all
> +    % in *different* maps (such as the module name A occurring in both
> +    % the int_import_context_map and the int_use_context_map of module B).
That looks fine otherwise.
Julien.
    
    
More information about the reviews
mailing list