From ffe5089275c0c4e5d885c37fb8e629a3b41bc509 Mon Sep 17 00:00:00 2001 From: Alex Malyshev Date: Fri, 30 May 2014 15:05:23 -0700 Subject: [PATCH] Add ConstStringDataMap typedef Summary: Need it for a later diff. Reviewed By: @jano Differential Revision: D1355266 --- hphp/runtime/base/type-string.h | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/hphp/runtime/base/type-string.h b/hphp/runtime/base/type-string.h index e6e65860bb1..9a8f8e34634 100644 --- a/hphp/runtime/base/type-string.h +++ b/hphp/runtime/base/type-string.h @@ -452,8 +452,18 @@ struct string_data_lt { } }; -typedef hphp_hash_set - ConstStringDataSet; +template using ConstStringDataMap = hphp_hash_map< + const StringData*, + T, + string_data_hash, + string_data_same +>; + +using ConstStringDataSet = hphp_hash_set< + const StringData*, + string_data_hash, + string_data_same +>; struct hphp_string_hash { size_t operator()(const String& s) const { -- 2.11.4.GIT