Closed poorna2152 closed 2 years ago
Following the nBallerina implementation for representation of maps. Added the field $hash to the $String type. Initialize the $hash field with the value -1 when creating a string. Hash of a string is calculated only once. Use the hash function, https://github.com/google/closure-library/blob/35b3ced07212ca684d68501a2134b0e1178c7771/closure/goog/string/string.js#L1163
$hash
$String
Following the nBallerina implementation for representation of maps. Added the field
$hash
to the$String
type. Initialize the$hash
field with the value -1 when creating a string. Hash of a string is calculated only once. Use the hash function, https://github.com/google/closure-library/blob/35b3ced07212ca684d68501a2134b0e1178c7771/closure/goog/string/string.js#L1163