use newly available character type in must_be/2

This commit is contained in:
Markus Triska
2020-07-11 19:52:01 +02:00
parent eb872f8fca
commit 0fa8feb475

View File

@@ -57,13 +57,7 @@
list_of_chars(Cs) :-
must_be(list, Cs),
( ground(Cs) ->
( member(C, Cs), \+ atom_length(C, 1) ->
type_error(char, C, files_and_directories)
; true
)
; instantiation_error(s)
).
maplist(must_be(character), Cs).
directory_files(Directory, Files) :-
list_of_chars(Directory),