clang_generator: Use a btree_map for fixed iteration order

PiperOrigin-RevId: 435291910
Change-Id: I198247409d095183849a221af9c3be21b5bb859b
This commit is contained in:
Christian Blichmann 2022-03-17 02:42:30 -07:00 committed by Copybara-Service
parent d5ebb81598
commit b8579e4746
2 changed files with 3 additions and 2 deletions

View File

@ -41,6 +41,7 @@ llvm_map_components_to_libnames(_sapi_generator_llvm_libs
)
target_link_libraries(sapi_generator PUBLIC
sapi::base
absl::btree
absl::flat_hash_set
absl::memory
absl::random_random

View File

@ -18,7 +18,7 @@
#include <string>
#include <vector>
#include "absl/container/flat_hash_map.h"
#include "absl/container/btree_map.h"
#include "absl/status/status.h"
#include "absl/status/statusor.h"
#include "absl/strings/string_view.h"
@ -39,7 +39,7 @@ class GeneratorOptions;
class Emitter {
public:
using RenderedTypesMap =
absl::flat_hash_map<std::string, std::vector<std::string>>;
absl::btree_map<std::string, std::vector<std::string>>;
void CollectType(clang::QualType qual);
void CollectFunction(clang::FunctionDecl* decl);