1--TEST--
2WeakReference serials
3--FILE--
4<?php
5$wr = WeakReference::create(new stdClass);
6
7try {
8    serialize($wr);
9} catch (Exception $ex) {
10    var_dump($ex->getMessage());
11}
12
13$wrs = 'O:13:"WeakReference":0:{}';
14
15var_dump(@unserialize($wrs));
16?>
17--EXPECT--
18string(47) "Serialization of 'WeakReference' is not allowed"
19bool(false)
20