From: gabriele renzi Date: 2003-12-24T09:36:50+09:00 Subject: Re: Does String cache its 'hash' return value? il Wed, 24 Dec 2003 00:11:27 +0000, Asfand Yar Qazi ha scritto:: >> >> Yes, it will. Have you considered unsing Symbols instead of Strings? >> The hash value "calculation" of a Symbol is O(1). >> > >Depends... if Symbols are used as the keys for a hash table, can they be >as easily accessed from extension modules as if Strings were used? why the should'nt ? Many lybraries make use of symbols as constants, ruby-gtk or Pdf::Writer are examples.. and, btw "everything is an object" make everything work as everything else :)