comparedIdIn function

String comparedIdIn(
  1. String package,
  2. String id
)

How a row is addressed when a comparison spans several packages.

The package's own path, worktree-relative, in front of the id the row has inside that package — so the whole thing reads as the file's path plus the name it was declared under, and needs no separator nobody has seen before.

Applied only when a run touches more than one package. Qualifying unconditionally would rename every id in every single-package project to buy nothing, and ids travel: they are in deep links, in the pull-request comment's table, and in whatever a consumer's script filters on.

Implementation

String comparedIdIn(String package, String id) =>
    package.isEmpty ? id : '$package/$id';