[res] Simplify XmlPullParser::FindAttribute() and StringPool::Sort

1. FindAttribute used to do lots of work that C++17 does
   automatically

2. Use function_ref for a more efficient callback passing

Test: aapt2_tests
Flag: EXEMPT minor refactor
Change-Id: I4f172cca16c05422992b107e347ed01479fff898
4 files changed