Andres Valloud wrote: > Nicolas, > > Would you like Martin's approach better if the selector was > #basicIdentityHash instead of #primIdentityHash? Is it a matter of > naming only, or is there something else? > > Andres. > > Nicolas Cellier wrote: >> After-thoughts: my opinion is: >> Martin solution is more pragmatical : it is tailored for getting most >> improvment with minimal change in system. >> But formally, I prefer Andres design for it's clarity. >> - I do not like the idea that #identityHash and #primIdentityHash do >> behave differently >> - #scaledIdentityHash does clearly express itself on the contrary >> But that turns into german discussions ;)
My thoughts in choosing the naming: #identityHash Answers a value with a good range, suitable for general use, can be used in code that is portable across Smalltalk dialects. Today the range is not good across all dialects, but maybe this will improve if we start the movement here in Pharo). #primIdentityHash Used (almost) only by ProtoObject>>identityHash. Has a limited range; that range might get better when VM/image format changes. Could also be used by packages that want to do something very special and don't care that they will not be portable across dialects. The use in MethodDictionary is an example of this special non-portable use. I'd certainly be open to a better name for #primIdentityHash. Regards, -Martin _______________________________________________ Pharo-project mailing list [email protected] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
