From 87a9979c8938b800aab6e35903d60d24892e7f2e Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Thu, 19 Oct 2017 17:18:17 +0200 Subject: overload std::hash for OUString and OString no need to explicitly specify it anymore Change-Id: I6ad9259cce77201fdd75152533f5151aae83e9ec Reviewed-on: https://gerrit.libreoffice.org/43567 Tested-by: Jenkins Reviewed-by: Noel Grandin --- extensions/source/bibliography/framectr.cxx | 2 +- extensions/source/ole/oleobjw.hxx | 4 ++-- extensions/source/ole/unoobjw.hxx | 6 ++---- extensions/source/propctrlr/eventhandler.cxx | 2 +- extensions/source/propctrlr/eventhandler.hxx | 2 +- extensions/source/propctrlr/pcrcommontypes.hxx | 2 +- extensions/source/propctrlr/propcontroller.hxx | 6 +++--- 7 files changed, 11 insertions(+), 13 deletions(-) (limited to 'extensions') diff --git a/extensions/source/bibliography/framectr.cxx b/extensions/source/bibliography/framectr.cxx index 885630c168b2..191131b068a2 100644 --- a/extensions/source/bibliography/framectr.cxx +++ b/extensions/source/bibliography/framectr.cxx @@ -100,7 +100,7 @@ static const DispatchInfo SupportedCommandsArray[] = { nullptr , 0 , false } }; -typedef std::unordered_map< OUString, CacheDispatchInfo, OUStringHash > CmdToInfoCache; +typedef std::unordered_map< OUString, CacheDispatchInfo > CmdToInfoCache; const CmdToInfoCache& GetCommandToInfoCache() { diff --git a/extensions/source/ole/oleobjw.hxx b/extensions/source/ole/oleobjw.hxx index c46530290873..dbf1b74924eb 100644 --- a/extensions/source/ole/oleobjw.hxx +++ b/extensions/source/ole/oleobjw.hxx @@ -50,9 +50,9 @@ namespace ole_adapter { -typedef std::unordered_map, OUStringHash> DispIdMap; +typedef std::unordered_map> DispIdMap; -typedef std::unordered_multimap TLBFuncIndexMap; +typedef std::unordered_multimap TLBFuncIndexMap; // This class wraps an IDispatch and maps XInvocation calls to IDispatch calls on the wrapped object. // If m_TypeDescription is set then this class represents an UNO interface implemented in a COM component. diff --git a/extensions/source/ole/unoobjw.hxx b/extensions/source/ole/unoobjw.hxx index a92cf97b2bfc..22036dbe4762 100644 --- a/extensions/source/ole/unoobjw.hxx +++ b/extensions/source/ole/unoobjw.hxx @@ -78,15 +78,13 @@ struct MemberInfo typedef std::unordered_map < OUString, - DISPID, - OUStringHash + DISPID > NameToIdMap; typedef std::unordered_map < OUString, - bool, - OUStringHash + bool > BadNameMap; typedef std::unordered_map diff --git a/extensions/source/propctrlr/eventhandler.cxx b/extensions/source/propctrlr/eventhandler.cxx index 35fb2a3ae551..1d219329c66c 100644 --- a/extensions/source/propctrlr/eventhandler.cxx +++ b/extensions/source/propctrlr/eventhandler.cxx @@ -309,7 +309,7 @@ namespace pcr class EventHolder : public EventHolder_Base { private: - typedef std::unordered_map< OUString, ScriptEventDescriptor, OUStringHash > EventMap; + typedef std::unordered_map< OUString, ScriptEventDescriptor > EventMap; typedef std::map< EventId, EventMap::iterator > EventMapIndexAccess; EventMap m_aEventNameAccess; diff --git a/extensions/source/propctrlr/eventhandler.hxx b/extensions/source/propctrlr/eventhandler.hxx index c1d3c72214b6..21e87766a07d 100644 --- a/extensions/source/propctrlr/eventhandler.hxx +++ b/extensions/source/propctrlr/eventhandler.hxx @@ -65,7 +65,7 @@ namespace pcr const OString& _sUniqueBrowseId ); }; - typedef std::unordered_map< OUString, EventDescription, OUStringHash > EventMap; + typedef std::unordered_map< OUString, EventDescription > EventMap; //= EventHandler diff --git a/extensions/source/propctrlr/pcrcommontypes.hxx b/extensions/source/propctrlr/pcrcommontypes.hxx index 19c85ba47330..0fe62c6330c5 100644 --- a/extensions/source/propctrlr/pcrcommontypes.hxx +++ b/extensions/source/propctrlr/pcrcommontypes.hxx @@ -30,7 +30,7 @@ namespace pcr { - typedef std::unordered_map< OUString, css::beans::Property, OUStringHash > + typedef std::unordered_map< OUString, css::beans::Property > PropertyMap; diff --git a/extensions/source/propctrlr/propcontroller.hxx b/extensions/source/propctrlr/propcontroller.hxx index 8d937f7b6a30..efb18ec27a84 100644 --- a/extensions/source/propctrlr/propcontroller.hxx +++ b/extensions/source/propctrlr/propcontroller.hxx @@ -110,9 +110,9 @@ namespace pcr typedef css::uno::Reference< css::inspection::XPropertyHandler > PropertyHandlerRef; typedef std::vector< PropertyHandlerRef > PropertyHandlerArray; - typedef std::unordered_map< OUString, PropertyHandlerRef, OUStringHash > + typedef std::unordered_map< OUString, PropertyHandlerRef > PropertyHandlerRepository; - typedef std::unordered_multimap< OUString, PropertyHandlerRef, OUStringHash > + typedef std::unordered_multimap< OUString, PropertyHandlerRef > PropertyHandlerMultiRepository; PropertyHandlerRepository m_aPropertyHandlers; PropertyHandlerMultiRepository m_aDependencyHandlers; @@ -130,7 +130,7 @@ namespace pcr /// the property we're just committing OUString m_sCommittingProperty; - typedef std::unordered_map< OUString, sal_uInt16, OUStringHash > HashString2Int16; + typedef std::unordered_map< OUString, sal_uInt16 > HashString2Int16; HashString2Int16 m_aPageIds; bool m_bContainerFocusListening; -- cgit