We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 12ee656 commit dad63c7Copy full SHA for dad63c7
src/Reflection/Php/PhpMethodReflection.php
@@ -330,11 +330,9 @@ private function getNativeReturnType(): Type
330
return $this->nativeReturnType = new VoidType();
331
}
332
if ($name === '__tostring') {
333
- if ($this->declaringClass->isBuiltin()) {
334
- return $this->nativeReturnType = new StringType();
335
- } else {
336
- return $this->nativeReturnType = new MixedType();
337
- }
+ return $this->nativeReturnType = $this->declaringClass->isBuiltin()
+ ? new StringType()
+ : new MixedType();
338
339
if ($name === '__isset') {
340
return $this->nativeReturnType = new BooleanType();
0 commit comments