@ -337,17 +337,17 @@ let proc_calls resolve_attributes pdesc filter : (Procname.t * ProcAttributes.t)
List . iter ~ f : do_node nodes ; List . rev ! res
List . iter ~ f : do_node nodes ; List . rev ! res
let is_override_of proc_name =
let has_same_signature proc_name =
let sub_ method_name = Procname . get_method proc_name in
let method_name = Procname . get_method proc_name in
let sub_ params = Procname . get_parameters proc_name in
let params = Procname . get_parameters proc_name in
Staged . stage ( fun sup er_pname ->
Staged . stage ( fun oth er_pname ->
let super_method_name = Procname . get_method sup er_pname in
let other_method_name = Procname . get_method oth er_pname in
let super_params = Procname . get_parameters sup er_pname in
let other_params = Procname . get_parameters oth er_pname in
( not ( Procname . is_constructor sup er_pname) )
( not ( Procname . is_constructor oth er_pname) )
&& String . equal super_method_name sub_ method_name
&& String . equal other_method_name method_name
(* Check that parameter types match exactly ( no subtyping or what not ) . *)
(* Check that parameter types match exactly ( no subtyping or what not ) . *)
&&
&&
match List . for_all2 sub_params sup er_params ~ f : Procname . Parameter . equal with
match List . for_all2 params oth er_params ~ f : Procname . Parameter . equal with
| List . Or_unequal_lengths . Ok res ->
| List . Or_unequal_lengths . Ok res ->
res
res
| List . Or_unequal_lengths . Unequal_lengths ->
| List . Or_unequal_lengths . Unequal_lengths ->
@ -355,7 +355,7 @@ let is_override_of proc_name =
let override_find ? ( check_current_type = true ) f tenv proc_name =
let override_find ? ( check_current_type = true ) f tenv proc_name =
let is_override = Staged . unstage ( is_override_of proc_name ) in
let is_override = Staged . unstage ( has_same_signature proc_name ) in
let rec find_super_type super_class_name =
let rec find_super_type super_class_name =
Tenv . lookup tenv super_class_name
Tenv . lookup tenv super_class_name
| > Option . bind ~ f : ( fun { Struct . methods ; supers } ->
| > Option . bind ~ f : ( fun { Struct . methods ; supers } ->