Skip to content

Commit

Permalink
https://github.com/mage2pro/core/issues/435
Browse files Browse the repository at this point in the history
  • Loading branch information
dmitrii-fediuk committed Sep 21, 2024
1 parent c35fbbb commit eeb72b0
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions Core/lib/reflection/param/type.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?php
use ReflectionNamedType as NT; # 2024-09-21 https://www.php.net/manual/en/class.reflectionnamedtype.php
use ReflectionParameter as P;

/**
* 2024-09-21
* https://www.php.net/manual/en/reflectionparameter.gettype.php
* https://www.php.net/manual/en/class.reflectionnamedtype.php
* https://www.php.net/manual/en/reflectionnamedtype.getname.php#128874
*/
function dfr_param_type(P $p):string {return ($t = $p->getType()) instanceof NT ? $t->getName() : '';}

0 comments on commit eeb72b0

Please sign in to comment.