[aapt2] Fix the sorting in ResourceTable for flagged entries

+ a few C++ style fixes that are supposed to be noops, but with
  the existing perf test regression record I'm not sure anymore

Flag: EXEMPT bugfix
Test: build + boot + aapt2_tests
Change-Id: I918448ddc3840e1a180466d794eb81e8ec4b9640
1 file changed