Skip to content

Commit 4c17e66

Browse files
committed
Add clarifying comment
1 parent 84e60e7 commit 4c17e66

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tests/r8-method-overloading.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,9 +87,11 @@ const RETRACE_MAPPING_WITH_OVERLOADS_MAPPING: &str = r#"some.Class -> A:
8787
fn test_retrace_mapping_with_overloads_api_has_2_candidates() {
8888
let mapper = ProguardMapper::from(RETRACE_MAPPING_WITH_OVERLOADS_MAPPING);
8989

90-
// Equivalent to upstream's `retracer.retraceClass(A).lookupMethod("a")` size == 2:
90+
// Equivalent to upstream's `retracer.retraceClass(A).lookupMethod("a").narrowByPosition()` size == 2:
9191
// - sync() (line-mapped range)
9292
// - cancel(java.lang.String[])
93+
// The original test uses `lookupMethod("a") which is expected to return 3 candidates here,
94+
// but our implementation already bakes narrowByPosition() in, hence we expect 2`
9395
let frame = StackFrame::new("A", "a", 0);
9496
let remapped: Vec<_> = mapper.remap_frame(&frame).collect();
9597
assert_eq!(remapped.len(), 2);

0 commit comments

Comments
 (0)