summaryrefslogtreecommitdiffstats
path: root/docs/nspr/reference/pl_hashstring.rst
blob: 3c6b8cde5f36d7ca65a9692bd8ba858c53fa3b70 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
PL_HashString
=============

A general-purpose hash function for character strings.


Syntax
------

.. code::

   #include <plhash.h>

   PLHashNumber PL_HashString(const void *key);


Parameter
~~~~~~~~~

The function has the following parameter:

``key``
   A pointer to a character string.


Returns
~~~~~~~

The hash number for the specified key.


Description
-----------

:ref:`PL_HashString` can be used as the key hash function for a hash table
if the key is a character string.