Index: third_party/mojo/src/mojo/public/cpp/bindings/lib/map_data_internal.h |
diff --git a/third_party/mojo/src/mojo/public/cpp/bindings/lib/map_data_internal.h b/third_party/mojo/src/mojo/public/cpp/bindings/lib/map_data_internal.h |
index 6d629b40e8aba7ed02af947b435a3d5df4a4643a..8315dbc8e10e615ba4437c21174ba628dc3c5b5a 100644 |
--- a/third_party/mojo/src/mojo/public/cpp/bindings/lib/map_data_internal.h |
+++ b/third_party/mojo/src/mojo/public/cpp/bindings/lib/map_data_internal.h |
@@ -13,24 +13,21 @@ |
namespace mojo { |
namespace internal { |
-namespace { |
-const ArrayValidateParams* GetMapKeyValidateParamsDefault() { |
- // The memory allocated here never gets released because calling a |
- // destructor at exit time makes clang unhappy. |
+inline const ArrayValidateParams* GetMapKeyValidateParamsDefault() { |
+ // The memory allocated here never gets released to not cause an exit time |
+ // destructor. |
static const ArrayValidateParams* validate_params = |
new ArrayValidateParams(0, false, nullptr); |
return validate_params; |
} |
-const ArrayValidateParams* GetMapKeyValidateParamsForStrings() { |
- // The memory allocated here never gets released because calling a |
- // destructor at exit time makes clang unhappy. |
+inline const ArrayValidateParams* GetMapKeyValidateParamsForStrings() { |
+ // The memory allocated here never gets released to not cause an exit time |
+ // destructor. |
static const ArrayValidateParams* validate_params = new ArrayValidateParams( |
0, false, new ArrayValidateParams(0, false, nullptr)); |
return validate_params; |
} |
- |
-} // namespace |
template <typename MapKey> |
struct MapKeyValidateParamsFactory { |