_createModuleHash(
		module,
		chunkGraph,
		runtime,
		hashFunction,
		runtimeTemplate,
		hashDigest,
		hashDigestLength,
		errors
	) {
		let moduleHashDigest;
		try {
			const moduleHash = createHash(/** @type {HashFunction} */ (hashFunction));
			module.updateHash(moduleHash, {
				chunkGraph,
				runtime,
				runtimeTemplate
			});
			moduleHashDigest = /** @type {string} */ (moduleHash.digest(hashDigest));
		} catch (err) {
			errors.push(new ModuleHashingError(module, /** @type {Error} */ (err)));
			moduleHashDigest = "XXXXXX";
		}
		chunkGraph.setModuleHashes(
			module,
			runtime,
			moduleHashDigest,
			moduleHashDigest.slice(0, hashDigestLength)
		);
		return moduleHashDigest;
	}
@private
@param {Module} module module
@param {ChunkGraph} chunkGraph the chunk graph
@param {RuntimeSpec} runtime runtime
@param {OutputOptions["hashFunction"]} hashFunction hash function
@param {RuntimeTemplate} runtimeTemplate runtime template
@param {OutputOptions["hashDigest"]} hashDigest hash digest
@param {OutputOptions["hashDigestLength"]} hashDigestLength hash digest length
@param {WebpackError[]} errors errors
@returns {string} module hash digest