I have done some tests with the next minor Version of PHP
(7.1beta
).
During the tests with void return types I noticed that gettype returns NULL
for a void method. Can anyone explain why it does that?
function returnVoid(): void {
return;
}
echo gettype(returnVoid()); // returns "NULL"
Is this the expected behavior?