1--TEST--
2Hash: xxHash seed deprecation of edge cases
3--FILE--
4<?php
5
6foreach (["xxh32", "xxh64", "xxh3", "xxh128"] as $a) {
7	hash_init($a, options: ["seed" => "42"]);
8}
9
10foreach (["xxh3", "xxh128"] as $a) {
11    try {
12	    hash_init($a, options: ["secret" => 42]);
13	} catch (Throwable) {}
14}
15
16?>
17--EXPECTF--
18Deprecated: hash_init(): Passing a seed of a type other than int is deprecated because it is the same as setting the seed to 0 in %s on line %d
19
20Deprecated: hash_init(): Passing a seed of a type other than int is deprecated because it is the same as setting the seed to 0 in %s on line %d
21
22Deprecated: hash_init(): Passing a seed of a type other than int is deprecated because it is ignored in %s on line %d
23
24Deprecated: hash_init(): Passing a seed of a type other than int is deprecated because it is ignored in %s on line %d
25
26Deprecated: hash_init(): Passing a secret of a type other than string is deprecated because it implicitly converts to a string, potentially hiding bugs in %s on line %d
27
28Deprecated: hash_init(): Passing a secret of a type other than string is deprecated because it implicitly converts to a string, potentially hiding bugs in %s on line %d
29