public static int hash(char[] buffer, int offset, int len) {
        int h = 0;
        int off = offset;

        for (int i = 0; i < len; i++) {
            h = 31 * h + buffer[off++];
        }
        return h;
    }
Adds the specified symbol to the symbol table and returns a reference to the unique symbol. If the symbol already
exists, the previous symbol reference is returned instead, in order guarantee that symbol references remain
unique.

@param buffer The buffer containing the new symbol.
@param offset The offset into the buffer of the new symbol.
@param len The length of the new symbol in the buffer.
src/main/java/com/alibaba/fastjson/parser/SymbolTable.java