1--TEST-- 2Test __sleep returns non-array 3--FILE-- 4<?php 5class foo 6{ 7 private $private = 'private'; 8} 9 10class bar extends foo 11{ 12 public function __sleep() 13 { 14 return (new bar()); 15 } 16} 17 18serialize(new bar()); 19?> 20--EXPECTF-- 21Warning: serialize(): "private" returned as member variable from __sleep() but does not exist in %s on line %d 22 23