From 0cb69c5a6a09b50aee66199b7d89739ef981664d Mon Sep 17 00:00:00 2001 From: Jeremy Dubreil Date: Tue, 20 Dec 2016 11:13:43 -0800 Subject: [PATCH] [infer][java] fix comments for Annotations.annot_ends_with Summary: The comment was not clear Reviewed By: jberdine Differential Revision: D4345705 fbshipit-source-id: 49c4615 --- infer/src/checkers/annotations.ml | 3 ++- infer/src/checkers/annotations.mli | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/infer/src/checkers/annotations.ml b/infer/src/checkers/annotations.ml index 424a81388..ba6a3b45d 100644 --- a/infer/src/checkers/annotations.ml +++ b/infer/src/checkers/annotations.ml @@ -48,7 +48,8 @@ let ia_has_annotation_with ia; !found -(** Return true if [annot] ends with [ann_name], ignoring the package name *) +(** [annot_ends_with annot ann_name] returns true if the class name of [annot], without the package, + is equal to [ann_name] *) let annot_ends_with annot ann_name = match String.rsplit2 annot.Annot.class_name ~on:'.' with | None -> String.equal annot.Annot.class_name ann_name diff --git a/infer/src/checkers/annotations.mli b/infer/src/checkers/annotations.mli index 753025f99..864c793b0 100644 --- a/infer/src/checkers/annotations.mli +++ b/infer/src/checkers/annotations.mli @@ -54,7 +54,8 @@ val get_annotated_signature : ProcAttributes.t -> annotated_signature val nullable : string -(** Return true if [annot] ends with [ann_name] *) +(** [annot_ends_with annot ann_name] returns true if the class name of [annot], without the package, + is equal to [ann_name] *) val annot_ends_with : Annot.t -> string -> bool (** Check if there is an annotation in [ia] which ends with the given name *)