mirror of
https://github.com/nim-lang/Nim.git
synced 2026-04-29 10:43:57 +00:00
Add hash proc for cstrings (#5386)
This commit is contained in:
committed by
Andreas Rumpf
parent
6fa1dba515
commit
92665e6e9a
@@ -18,7 +18,11 @@ Changes affecting backwards compatibility
|
||||
- The IO routines now raise ``EOFError`` for the "end of file" condition.
|
||||
``EOFError`` is a subtype of ``IOError`` and so it's easier to distinguish
|
||||
between "error during read" and "error due to EOF".
|
||||
|
||||
- A hash procedure has been added for ``cstring`` type in ``hashes`` module.
|
||||
Previously, hash of a ``cstring`` would be calculated as a hash of the
|
||||
pointer. Now the hash is calculated from the contents of the string, assuming
|
||||
``cstring`` is a null-terminated string. Equal ``string``s and ``cstring``s
|
||||
produce equal hash value.
|
||||
|
||||
Library Additions
|
||||
-----------------
|
||||
|
||||
Reference in New Issue
Block a user