View Source hank (rebar3_hank v1.4.0)

The Erlang Dead Code Cleaner

Link to this section Summary

Functions

Runs a list of rules over a list of files and returns all the dead code pieces it can find.

Link to this section Types

-type ms() :: non_neg_integer().
-type parsing_style() :: parallel | sequential.
-type stats() :: #{ignored := non_neg_integer(), parsing := ms(), analyzing => ms(), total => ms()}.

Link to this section Functions

Link to this function

analyze(Files, IgnoreSpecsFromState, Rules, ParsingStyle, Context)

View Source
-spec analyze([file:filename()],
        [hank_rule:ignore_spec()],
        [hank_rule:t()],
        parsing_style(),
        hank_context:t()) ->
           #{results := [hank_rule:result()],
             unused_ignores := [hank_rule:ignore_spec()],
             stats := stats()}.
Runs a list of rules over a list of files and returns all the dead code pieces it can find.
-spec get_ast(file:filename()) -> erl_syntax:forms().