Current section

Files

Jump to
cleam src cleam.erl
Raw

src/cleam.erl

-module(cleam).
-compile([no_auto_import, nowarn_unused_vars, nowarn_unused_function, nowarn_nomatch]).
-export([main/0]).
-spec main() -> nil.
main() ->
Not_used_fun = internal@checker:not_used_functions(
{files_dir, <<"src"/utf8>>},
{some, {files_dir, <<"test"/utf8>>}}
),
gleam@list:each(
Not_used_fun,
fun(Not_used_fun@1) ->
{{public_fun, Public_fun}, {file_path, File_path}} = Not_used_fun@1,
gleam@io:println_error(
<<<<<<"Function not used: "/utf8, Public_fun/binary>>/binary,
"; File path: "/utf8>>/binary,
File_path/binary>>
)
end
),
case gleam@list:length(Not_used_fun) > 0 of
true ->
erlang:halt(1);
false ->
erlang:halt(0)
end.