Switch ResourceName to use ResourceNamedType instead of ResourceType.
DD: go/custom-resource-types-in-aapt2
Bug: b/215108200
Test: Resource_test.cpp
Change-Id: I0b97fc0024523700e01adce788bb934d388da288
diff --git a/tools/aapt2/ResourceValues.cpp b/tools/aapt2/ResourceValues.cpp
index b3ab4ff..b796eb0 100644
--- a/tools/aapt2/ResourceValues.cpp
+++ b/tools/aapt2/ResourceValues.cpp
@@ -116,7 +116,7 @@
}
bool Reference::Flatten(android::Res_value* out_value) const {
- if (name && name.value().type == ResourceType::kMacro) {
+ if (name && name.value().type.type == ResourceType::kMacro) {
return false;
}
@@ -192,7 +192,7 @@
if (print_package) {
printer->Print(name.to_string());
} else {
- printer->Print(to_string(name.type));
+ printer->Print(name.type.to_string());
printer->Print("/");
printer->Print(name.entry);
}