<?php
class test {
function a() {
echo 'hi';
}
}
$class = new ReflectionClass('ReflectionClass');
$method = $class->getMethod('getMethod');
echo serialize($method);
Fatal error: Uncaught Exception: Serialization of 'ReflectionMethod' is not allowed in /in/QR3Ze:9
Stack trace:
#0 /in/QR3Ze(9): serialize(Object(ReflectionMethod))
#1 {main}
thrown in /in/QR3Ze on line 9
Process exited with code 255.