anchor.diff:  
   
   -spec macro_log(Location,Level,StringOrReport)  -> ok when
  -      Location :: map(),
  +      Location :: location(),
         Level :: level(),
         StringOrReport :: unicode:chardata() | report().
   macro_log(Location,Level,StringOrReport) ->
       log_allowed(Location,Level,StringOrReport,#{}).
   
   -spec macro_log(Location,Level,StringOrReport,Meta)  -> ok when
  -      Location :: map(),
  +      Location :: location(),
         Level :: level(),
         StringOrReport :: unicode:chardata() | report(),
         Meta :: metadata();
                  (Location,Level,Format,Args) -> ok when
  -      Location :: map(),
  +      Location :: location(),
         Level :: level(),
         Format :: io:format(),
         Args ::[term()];
                  (Location,Level,Fun,FunArgs) -> ok when
  -      Location :: map(),
  +      Location :: location(),
         Level :: level(),
         Fun :: msg_fun(),
         FunArgs :: term().
  
positive.code: 
  %%%-----------------------------------------------------------------
  %%% Types
  -type log() :: #{level=>level(),
                   msg=>{io:format(),[term()]} |
                        {report,report()} |
                        {string,unicode:chardata()},
                   meta=>metadata()}.
  -type level() :: emergency | alert | critical | error |
                   warning | notice | info | debug.
  -type report() :: map() | [{atom(),term()}].
  -type msg_fun() :: fun((term()) -> {io:format(),[term()]} |
                                     report() |
                                     unicode:chardata()).
  -type metadata() :: map().
  
  -type handler_id() :: atom().
  -type filter_id() :: atom().
  -type filter() :: {fun((log(),term()) -> filter_return()),term()}.
  -type filter_return() :: stop | ignore | log().
  -type config() :: map().
  
  -export_type([log/0,level/0,report/0,msg_fun/0,metadata/0,config/0,handler_id/0,
                filter_id/0,filter/0,filter_return/0]).
  
  %%%-----------------------------------------------------------------
  %%% API
  
negative.code:     end.
  
  -spec log_allowed(Location,Level,Msg,Meta)  -> ok when
        Location :: location() | #{},
        Level :: level(),
        Msg :: {msg_fun(),term()} |
               {io:format(),[term()]} |
  