]> git.ipfire.org Git - thirdparty/make.git/commit
Add ISDIRSEP() helper macro and use it
authorPaul Smith <psmith@gnu.org>
Tue, 18 Oct 2022 03:36:36 +0000 (23:36 -0400)
committerPaul Smith <psmith@gnu.org>
Tue, 18 Oct 2022 18:20:44 +0000 (14:20 -0400)
commit7bb7bb4ba49967e71abf14d7d59036b9a0eddf93
tree2895b178787d4028941a4ef116ec4365ac5f8b24
parentb79791533bf2a784bf201fbb9f63588ef24fc404
Add ISDIRSEP() helper macro and use it

Create a ISDIRSEP() macro to check for directory separator chars
using the stopchar_map, and replace inline checks and explicit
STOP_SET calls with this macro.

* src/makeint.h (ISDIRSEP): Create the macro using MAP_DIRSEP.
* src/dir.c (find_directory): Replace inline checks with ISDIRSEP.
(file_exists_p): Ditto.
(file_impossible): Ditto.
(file_impossible_p): Ditto.
(local_stat): Ditto.
* src/file.c (lookup_file): Ditto.
* src/function.c (abspath): Ditto.
* src/job.c (_is_unixy_shell): Ditto.
(is_bourne_compatible_shell): Ditto.
(construct_command_argv): Ditto.
* src/main.c (find_and_set_default_shell): Ditto.
(main): Ditto.
* src/read.c (eval): Ditto.
(parse_file_seq): Ditto.
* src/remake.c (name_mtime): Ditto.
* src/vpath.c (construct_vpath_list): Ditto.
src/dir.c
src/file.c
src/function.c
src/job.c
src/main.c
src/makeint.h
src/read.c
src/remake.c
src/vpath.c