anchor.diff:      ]).
   
   -export([
  -	t_build_and_match_literals/1,
  -	t_update_literals/1,t_match_and_update_literals/1,
  +	t_build_and_match_literals/1, t_build_and_match_literals_large/1,
  +	t_update_literals/1, t_update_literals_large/1,
  +        t_match_and_update_literals/1, t_match_and_update_literals_large/1,
   	t_update_map_expressions/1,
  -	t_update_assoc/1,t_update_exact/1,
  +	t_update_assoc/1, t_update_assoc_large/1,
  +        t_update_exact/1, t_update_exact_large/1,
   	t_guard_bifs/1, t_guard_sequence/1, t_guard_update/1,
   	t_guard_receive/1, t_guard_fun/1,
   	t_list_comprehension/1,
  
positive.code: 	]),
      ok.
  
  loop_update_literals_x_q(Map, []) -> Map;
  loop_update_literals_x_q(Map, [{X,Q}|Vs]) ->
      loop_update_literals_x_q(Map#{q=>Q,x=>X},Vs).
  
  % test map updates with matching
  t_match_and_update_literals(Config) when is_list(Config) ->
      Map = #{x=>0,y=>"untouched",z=>"also untouched",q=>1},
      #{x:=16,q:=21,y:="untouched",z:="also untouched"} = loop_match_and_update_literals_x_q(Map, [
  	    {1,2},{3,4},{5,6},{7,8}
  	]),
  
negative.code:     #{ 4 := another_number, int := 3 } = M2#{ 4 => another_number },
      ok.
  
  t_match_and_update_literals_large(Config) when is_list(Config) ->
      Map = id(#{ 10=>id(a0),20=>b0,30=>id("c0"),"40"=>"d0",<<"50">>=>id("e0"),{["00"]}=>"10",
                  11=>id(a1),21=>b1,31=>id("c1"),"41"=>"d1",<<"51">>=>id("e1"),{["01"]}=>"11",
                  12=>id(a2),22=>b2,32=>id("c2"),"42"=>"d2",<<"52">>=>id("e2"),{["02"]}=>"12",
                  13=>id(a3),23=>b3,33=>id("c3"),"43"=>"d3",<<"53">>=>id("e3"),{["03"]}=>"13",
                  14=>id(a4),24=>b4,34=>id("c4"),"44"=>"d4",<<"54">>=>id("e4"),{["04"]}=>"14",
  
                  15=>id(a5),25=>b5,35=>id("c5"),"45"=>"d5",<<"55">>=>id("e5"),{["05"]}=>"15",
                  16=>id(a6),26=>b6,36=>id("c6"),"46"=>"d6",<<"56">>=>id("e6"),{["06"]}=>"16",
                  17=>id(a7),27=>b7,37=>id("c7"),"47"=>"d7",<<"57">>=>id("e7"),{["07"]}=>"17",
                  18=>id(a8),28=>b8,38=>id("c8"),"48"=>"d8",<<"58">>=>id("e8"),{["08"]}=>"18",
                  19=>id(a9),29=>b9,39=>id("c9"),"49"=>"d9",<<"59">>=>id("e9"),{["09"]}=>"19",
  
                  10.0=>fa0,20.0=>id(fb0),30.0=>id("fc0"),
                  11.0=>fa1,21.0=>id(fb1),31.0=>id("fc1"),
                  12.0=>fa2,22.0=>id(fb2),32.0=>id("fc2"),
                  13.0=>fa3,23.0=>id(fb3),33.0=>id("fc3"),
                  14.0=>fa4,24.0=>id(fb4),34.0=>id("fc4"),
  
                  15.0=>fa5,25.0=>id(fb5),35.0=>id("fc5"),
                  16.0=>fa6,26.0=>id(fb6),36.0=>id("fc6"),
                  17.0=>fa7,27.0=>id(fb7),37.0=>id("fc7"),
                  18.0=>fa8,28.0=>id(fb8),38.0=>id("fc8"),
                  19.0=>fa9,29.0=>id(fb9),39.0=>id("fc9"),
  
                  x=>0,y=>"untouched",z=>"also untouched",q=>1,
  
                  #{ "one" => small, map => key } => id("small map key 1"),
                  #{ second => small, map => key } => "small map key 2",
                  #{ third => small, map => key } => "small map key 3",
  
                  #{ 10=>a0,20=>b0,30=>"c0","40"=>"d0",<<"50">>=>"e0",{["00"]}=>"10",
                     11=>a1,21=>b1,31=>"c1","41"=>"d1",<<"51">>=>"e1",{["01"]}=>"11",
                     12=>a2,22=>b2,32=>"c2","42"=>"d2",<<"52">>=>"e2",{["02"]}=>"12",
                     13=>a3,23=>b3,33=>"c3","43"=>"d3",<<"53">>=>"e3",{["03"]}=>"13",
                     14=>a4,24=>b4,34=>"c4","44"=>"d4",<<"54">>=>"e4",{["04"]}=>"14",
  
                     15=>a5,25=>b5,35=>"c5","45"=>"d5",<<"55">>=>"e5",{["05"]}=>"15",
                     16=>a6,26=>b6,36=>"c6","46"=>"d6",<<"56">>=>"e6",{["06"]}=>"16",
                     17=>a7,27=>b7,37=>"c7","47"=>"d7",<<"57">>=>"e7",{["07"]}=>"17",
                     18=>a8,28=>b8,38=>"c8","48"=>"d8",<<"58">>=>"e8",{["08"]}=>"18",
                     19=>a9,29=>b9,39=>"c9","49"=>"d9",<<"59">>=>"e9",{["09"]}=>"19" } => "large map key 1",
  
                  #{ 10=>a0,20=>b0,30=>"c0","40"=>"d0",<<"50">>=>"e0",{["00"]}=>"10",
                     11=>a1,21=>b1,31=>"c1","41"=>"d1",<<"51">>=>"e1",{["01"]}=>"11",
                     12=>a2,22=>b2,32=>"c2","42"=>"d2",<<"52">>=>"e2",{["02"]}=>"12",
                     13=>a3,23=>b3,33=>"c3","43"=>"d3",<<"53">>=>"e3",{["03"]}=>"13",
                     14=>a4,24=>b4,34=>"c4","44"=>"d4",<<"54">>=>"e4",{["04"]}=>"14",
  
                     15=>a5,25=>b5,35=>"c5","45"=>"d5",<<"55">>=>"e5",{["05"]}=>"15",
                     k16=>a6,k26=>b6,k36=>"c6","46"=>"d6",<<"56">>=>"e6",{["06"]}=>"16",
                     17=>a7,27=>b7,37=>"c7","47"=>"d7",<<"57">>=>"e7",{["07"]}=>"17",
                     18=>a8,28=>b8,38=>"c8","48"=>"d8",<<"58">>=>"e8",{["08"]}=>"18",
                     19=>a9,29=>b9,39=>"c9","49"=>"d9",<<"59">>=>"e9",{["09"]}=>"19" } => id("large map key 2") }),
  
      #{x:=16,q:=21,y:="untouched",z:="also untouched"} = loop_match_and_update_literals_x_q(Map, [
  	    {1,2},{3,4},{5,6},{7,8}
  	]),
      M0 = id(Map#{ "hi" => "hello", int => 3, <<"key">> => <<"value">>,
                    4 => number, 18446744073709551629 => wat}),
      M1 = id(Map#{}),
      M2 = M1#{ "hi" => "hello", int => 3, <<"key">> => <<"value">>,
                4 => number, 18446744073709551629 => wat},
      M0 = M2,
  
      #{ 4 := another_number, int := 3 } = M2#{ 4 => another_number },
      ok.
  
  loop_match_and_update_literals_x_q(Map, []) -> Map;
  loop_match_and_update_literals_x_q(#{ q:=Q0, x:=X0,
                                       #{ "one" => small, map => key } := "small map key 1" } = Map, [{X,Q}|Vs]) ->
      loop_match_and_update_literals_x_q(Map#{q=>Q0+Q,x=>X0+X},Vs).
  
  
  