anchor.diff:              end
       end,
       try
  -        InitialState = Module:init(Args),
  -        loop(Module, InitialState, {Options, 0.0})
  +        case Module:init(Args) of
  +            {'$gen_component', Config, InitialState} ->
  +                {value, {on_handler, NewHandler}} =
  +                    lists:keysearch(on_handler, 1, Config),
  +                loop(Module, NewHandler, InitialState, {Options, 0.0});
  +            InitialState ->
  +                loop(Module, on, InitialState, {Options, 0.0})
  +        end
       catch
           throw:Term ->
               log:log(error,"exception in init/loop of ~p: ~p~n", [Module, Term]),
  
positive.code: 
  -export([behaviour_info/1]).
  
  -export([start_link/2, start_link/3, start/4, start/2, start/3,wait_for_ok/0]).
  
  -export([kill/1, sleep/2]).
  
  
negative.code:                 {exception, Exception} ->
                      log:log(error,"Error: exception ~p during handling of ~p in module ~p~n",
                                [Exception, Message, Module]),
                      loop(Module, On, State, ComponentState);
                  unknown_event ->
                      {NewState, NewComponentState} =
                          handle_unknown_event(Message, State,
                           {Options, Slowest},Module),
                      loop(Module, On, NewState, NewComponentState);
                  kill ->
                      ok;
                  {'$gen_component', Config, NewState} ->
                      {value, {on_handler, NewHandler}} =
                          lists:keysearch(on_handler, 1, Config),
                      loop(Module, NewHandler, NewState, ComponentState);
                  NewState ->
                      %Stop = erlang:now(),
                      %Span = timer:now_diff(Stop, Start),
  