[m-rev.] for post-commit review: touched_files
Peter Wang
novalazy at gmail.com
Fri Dec 8 12:42:33 AEDT 2023
On Thu, 07 Dec 2023 20:37:49 +1100 "Zoltan Somogyi" <zoltan.somogyi at runbox.com> wrote:
> Group two args in a documented structure.
>
> Add a prefix to another type's field names.
> diff --git a/compiler/make.module_target.m b/compiler/make.module_target.m
> index 472f6b78a..d1c31b919 100644
> --- a/compiler/make.module_target.m
> +++ b/compiler/make.module_target.m
> @@ -266,19 +266,19 @@ make_module_target_file_main_path(ExtraOptions, ProgressStream, Globals,
>
> :- pred make_dependency_files(io.text_output_stream::in, globals::in,
> target_file::in, file_name::in, list(dependency_file)::in,
> - list(target_file)::in, list(file_name)::in, dependencies_result::out,
> + touched_files::in, dependencies_result::out,
> make_info::in, make_info::out, io::di, io::uo) is det.
>
> make_dependency_files(ProgressStream, Globals, TargetFile, TargetFileName,
> - DepFilesToMake, TouchedTargetFiles, TouchedFiles, DepsResult,
> - !Info, !IO) :-
> + DepFilesToMake, TouchedFiles, DepsResult, !Info, !IO) :-
> % Build the dependencies.
> - % ZZZ sort
> + % XXX MAKE sort
> KeepGoing = make_info_get_keep_going(!.Info),
> foldl2_make_module_targets(KeepGoing, [], ProgressStream, Globals,
> DepFilesToMake, MakeDepsSucceeded, !Info, !IO),
>
> % Check that the target files exist.
> + TouchedFiles = touched_files(TouchedTargetFiles, TouchedTimestampFiles),
> list.map_foldl2(
> get_target_timestamp(ProgressStream, Globals, do_not_search),
> TouchedTargetFiles, TargetTimestamps, !Info, !IO),
The name "TouchedTimestampFiles" (here and elsewhere),
when the list may include non-timestamp files, could be confusing.
Other than that, the diff is fine.
Peter
More information about the reviews
mailing list