[clang-tidy][NFC] Remove the double look-up on IncludeInserter
authorNathan James <n.james93@hotmail.co.uk>
Wed, 17 Jun 2020 18:48:12 +0000 (19:48 +0100)
committerNathan James <n.james93@hotmail.co.uk>
Wed, 17 Jun 2020 18:48:34 +0000 (19:48 +0100)
commit08c83ed75752169bdf27df8f5ea5978c53f2e258
tree1ac92658f37c2130c8ce1f0c8da188be65ae74d7
parent88c965ba14cff1e04ccb4237966a9fefe902b1f4
[clang-tidy][NFC] Remove the double look-up on IncludeInserter

Refactor out the double lookup in `IncludeInserter` when trying to get the `IncludeSorter` for a specified `FileID`.

Reviewed By: aaron.ballman

Differential Revision: https://reviews.llvm.org/D82004
clang-tools-extra/clang-tidy/utils/IncludeInserter.cpp
clang-tools-extra/clang-tidy/utils/IncludeInserter.h