anchor.diff:      << 16#D3:8, N:64/big-signed-integer-unit:1 >>.
   
   % nil
  -pack_nil()->
  -    << 16#C0:8 >>.
  +pack_nil()->    << 16#C0:8 >>.
   % pack_true / pack_false
   pack_bool(true)->    << 16#C3:8 >>;
   pack_bool(false)->   << 16#C2:8 >>.
  
positive.code: 
  % list / tuple
  pack_array(L) when is_list(L)->
      MaxLen = 16#10000, %65536
      case length(L) of
   	Len when Len < 16 ->
   	    << 2#1001:4, Len:4/integer-unit:1, (pack_array_(L))/binary >>;
  	Len when Len < MaxLen ->
  	    << 16#DC:8, Len:16/big-unsigned-integer-unit:1,(pack_array_(L))/binary >>;
  	Len ->
  	    << 16#DD:8, Len:32/big-unsigned-integer-unit:1,(pack_array_(L))/binary >>
  
negative.code: unpack_array_(Bin, RestLen, RetList) when is_binary(Bin)->
      case unpack(Bin) of
  	{more, Len} -> {more, Len+RestLen-1};
  	{Term, Rest}-> unpack_array_(Rest, RestLen-1, [Term|RetList])
      end.
  
  % FIXME: write test for pack_map/1
  pack_map(M)->
      case dict:size(M) of
  	Len when Len < 16 ->
   	    << 2#1001:4, Len:4/integer-unit:1, (pack_map_(dict:to_list(M))) >>;
  	Len when Len < 16#10000 -> % 65536
  	    << 16#DE:8, Len:16/big-unsigned-integer-unit:1, (pack_map_(dict:to_list(M)))/binary >>;
  	Len ->
  	    << 16#DF:8, Len:32/big-unsigned-integer-unit:1, (pack_map_(dict:to_list(M)))/binary >>
  