let collect_formal_ptr_call s px n b p =
try
let (arr,calls) = ByPReference.find px in
oracle "%s %a ByPRef" s pp_var_type px;
if n <= arr then
( oracle "%s %a + call(%a,%d,%s)" s pp_var_type px
pp_var_type p n (string_addr b);
ByPReference.replace px (arr,((n,(b,p))::calls)))
else
( oracle "%s %a remove %d used %d" s pp_var_type px arr n;
remove_ptr_reference_param px)
with Not_found ->
oracle "%s %a not yet ByPRef" s pp_var_type px;
if ByAReference.mem px then collect_formal_array_call s px n b p
else
begin
let arr = stars_var_type_typ px in add_ptr_reference_param px arr;
if ByPReference.mem px then
(if n <= arr then
( oracle "%s %a + call(%a,%d,%s)"
s pp_var_type px pp_var_type p n (string_addr b);
ByPReference.replace px (arr,[n,(b,p)])))
else ()
end