This patch changes the location specified to`ClangTidyCheck::diag()`.
Currently, the beginning of the matched range is used. This patch uses the
beginning of the first fix's range. This change both simplifies the code and
(hopefully) gives a more intuitive result: the reported location aligns with
the fix(es) provided, rather than the (arbitrary) range of the rule's match.
N.B. this patch will break the line offset numbers in lit tests if the first fix
is not at the beginning of the match.
Sorry, I don't quite understand the comment -- the test has two replacements (both arguments to the macro are replaced), but the comment says that we only expect one.