X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/edef87c8274bd4cadcccc4ff107aeb1815e48460..54ce9ebbd667147a18f119177422ce25011fe113:/include/wx/hashmap.h?ds=sidebyside diff --git a/include/wx/hashmap.h b/include/wx/hashmap.h index f068d6d93b..b2aa1bff1a 100644 --- a/include/wx/hashmap.h +++ b/include/wx/hashmap.h @@ -34,7 +34,7 @@ #endif #define _WX_DECLARE_HASH_MAP( KEY_T, VALUE_T, HASH_T, KEY_EQ_T, CLASSNAME, CLASSEXP ) \ - typedef WX_HASH_MAP_NAMESPACE::hash_map< KEY_T, VALUE_T, HASH_T, KEY_EQ_T > CLASSNAME; + typedef WX_HASH_MAP_NAMESPACE::hash_map< KEY_T, VALUE_T, HASH_T, KEY_EQ_T > CLASSNAME #else // !wxUSE_STL || !defined(HAVE_STL_HASH_MAP) @@ -344,10 +344,11 @@ protected: \ { \ if( m_equals( m_getKey( (*node)->m_value ), key ) ) \ return node; \ + /* Tell the compiler to not do any strict-aliasing assumptions with a void cast? Can we make such a runtime guarantee? */ \ node = (Node**)&(*node)->m_nxt; \ } \ \ - return 0; \ + return NULL; \ } \ \ /* returns NULL if not found */ \ @@ -640,7 +641,7 @@ public: \ /* count() == 0 | 1 */ \ size_type count( const const_key_type& key ) \ { return GetNode( key ) ? 1 : 0; } \ -}; +} #endif // !wxUSE_STL || !defined(HAVE_STL_HASH_MAP) @@ -699,7 +700,7 @@ public: \ // Declarations of common hashmap classes WX_DECLARE_HASH_MAP_WITH_DECL( long, long, wxIntegerHash, wxIntegerEqual, - wxLongToLongHashMap, class WXDLLIMPEXP_BASE ) + wxLongToLongHashMap, class WXDLLIMPEXP_BASE ); #endif // _WX_HASHMAP_H_