aboutsummaryrefslogtreecommitdiffstats
path: root/lib/stdlib/src
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2013-02-13 11:54:31 +0100
committerBjörn Gustavsson <[email protected]>2013-02-13 11:57:17 +0100
commite96b2bc546b13a30707479838f1a5891147a5603 (patch)
treeca837dc672a87ad334fff45dfdd5be73912830b7 /lib/stdlib/src
parent03b7c52a75c4af8d33b6b2a13bf7697709d3f6a3 (diff)
downloadotp-e96b2bc546b13a30707479838f1a5891147a5603.tar.gz
otp-e96b2bc546b13a30707479838f1a5891147a5603.tar.bz2
otp-e96b2bc546b13a30707479838f1a5891147a5603.zip
Don't allow binaries as the Cwd argument for filelib:wildcard()
filelib:wildcard() will no longer support "raw filenames", so it makes no sense for it to accept a binary Cwd argument.
Diffstat (limited to 'lib/stdlib/src')
-rw-r--r--lib/stdlib/src/filelib.erl4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/stdlib/src/filelib.erl b/lib/stdlib/src/filelib.erl
index ecc48e129d..853cf6a6fa 100644
--- a/lib/stdlib/src/filelib.erl
+++ b/lib/stdlib/src/filelib.erl
@@ -53,14 +53,14 @@ wildcard(Pattern) when is_list(Pattern) ->
-spec wildcard(Wildcard, Cwd) -> [file:filename()] when
Wildcard :: filename() | dirname(),
Cwd :: dirname().
-wildcard(Pattern, Cwd) when is_list(Pattern), (is_list(Cwd) or is_binary(Cwd)) ->
+wildcard(Pattern, Cwd) when is_list(Pattern), is_list(Cwd) ->
?HANDLE_ERROR(do_wildcard(Pattern, Cwd, file));
wildcard(Pattern, Mod) when is_list(Pattern), is_atom(Mod) ->
?HANDLE_ERROR(do_wildcard(Pattern, Mod)).
-spec wildcard(file:name(), file:name(), atom()) -> [file:filename()].
wildcard(Pattern, Cwd, Mod)
- when is_list(Pattern), (is_list(Cwd) or is_binary(Cwd)), is_atom(Mod) ->
+ when is_list(Pattern), is_list(Cwd), is_atom(Mod) ->
?HANDLE_ERROR(do_wildcard(Pattern, Cwd, Mod)).
-spec is_dir(Name) -> boolean() when