RFR (XS): 8004661: Comment and function name java_lang_String::toHash is wrong

Coleen Phillimore coleen.phillimore at oracle.com
Wed Dec 12 07:10:49 PST 2012


On 12/12/2012 8:42 AM, Erik Helin wrote:
> Bengt,
>
> On 12/12/2012 01:15 PM, Bengt Rutisson wrote:
>> Shouldn't the method be called hash_code() rather than hashCode() ?
>
> This is the standard we use throughout the codebase for the C++ code, 
> but I believe that the Coleen wanted the name of the method to match 
> the Java one.
>
> Coleen, did I understand this correctly?
>
> I'm fine with using any one of hashCode or hash_code, I think both 
> suggestions make sense.

Yes, I think it should be hash_code to follow our coding conventions but 
the comments should say hashCode (to match the jdk name). Otherwise, 
looks great.

Thanks!
Coleen

>
> On 12/12/2012 01:15 PM, Bengt Rutisson wrote:
>> Other than that it looks good to me.
>
> Thanks!
>
> Erik
>
>> Bengt
>>
>> On 12/12/12 10:27 AM, Erik Helin wrote:
>>> Hi all,
>>>
>>> the webrev is located at:
>>> http://cr.openjdk.java.net/~ehelin/8004661/webrev.00/
>>>
>>> Bug:
>>> http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=8004661
>>>
>>> Summary:
>>> I've renamed the function to_hash to hashCode and also updated the
>>> comments to use hashCode instead of to_hash.
>>>
>>> Testing:
>>> JPRT
>>>
>>> Thanks,
>>> Erik
>>>
>>
>



More information about the hotspot-runtime-dev mailing list