X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/a4f245269713c408d5e3fc2639a9bb9d9d218a93..df7145da50005a9f512d8f3329b6ed2166e956d0:/include/wx/hashmap.h diff --git a/include/wx/hashmap.h b/include/wx/hashmap.h index 83c63c35c3..801a036140 100644 --- a/include/wx/hashmap.h +++ b/include/wx/hashmap.h @@ -363,9 +363,15 @@ public: \ #define _WX_DECLARE_HASH_MAP_KEY_EX( KEY_T, PAIR_T, CLASSNAME, CLASSEXP ) \ CLASSEXP CLASSNAME \ { \ + typedef KEY_T key_type; \ + typedef PAIR_T pair_type; \ + typedef const key_type const_key_type; \ + typedef const pair_type const_pair_type; \ + typedef const_key_type& const_key_reference; \ + typedef const_pair_type& const_pair_reference; \ public: \ CLASSNAME() { } \ - KEY_T operator()( PAIR_T pair ) const { return pair.first; } \ + const_key_reference operator()( const_pair_reference pair ) const { return pair.first; }\ \ /* the dummy assignment operator is needed to suppress compiler */ \ /* warnings from hash table class' operator=(): gcc complains about */ \