comparison java/src/java/util/WeakHashMap.d @ 21:9b96950f2c3c

the 'java' tree compiles on both D1-Tango and D2-Phobos
author Frank Benoit <benoit@tionex.de>
date Thu, 19 Mar 2009 20:38:55 +0100
parents 6dd524f61e62
children
comparison
equal deleted inserted replaced
20:dccb717aa902 21:9b96950f2c3c
19 ptr = cast(size_t)cast(void*)k; 19 ptr = cast(size_t)cast(void*)k;
20 } 20 }
21 override hash_t toHash(){ 21 override hash_t toHash(){
22 return cast(hash_t)ptr; 22 return cast(hash_t)ptr;
23 } 23 }
24 override int opEquals( Object o ){ 24 override equals_t opEquals( Object o ){
25 if( auto other = cast(Ref)o ){ 25 if( auto other = cast(Ref)o ){
26 return ptr is other.ptr; 26 return ptr is other.ptr;
27 } 27 }
28 return false; 28 return false;
29 } 29 }