I have a scenario in which my server side code runs in an x86 environment where the client side runs in x64. The problem is that we use String.GetHashCode () to identify the objects in the HashTable, because "the behavior of GetHashCode depends on its implementation, which may vary from one version of the common language runtime to another." -MSDN. I used unsafe code to create an x86 equivalent GetHashCode () from the following question: Can I depend on the values of GetHashCode () so that they are consistent? . p>
I had a few questions:
A created and extensible method that generates a HashCode for the provided string, so that it will be the same even if the client and server are running in different environments (x86 or x64).