contents)) { $docstring = []; foreach (\explode("\n", $r->contents) as $line) { $docstring[] = \trim($line); } $docstring = $this->renderer->escape(\implode("\n", $docstring)); } $addendum = []; if (isset($r->class) && $r->inherited) { $addendum[] = 'Inherited from '.$this->renderer->escape($r->class); } if (isset($r->file, $r->line)) { $addendum[] = 'Defined in '.$this->renderer->escape(Kint::shortenPath($r->file)).':'.((int) $r->line); } if ($addendum) { $addendum = ''.\implode("\n", $addendum).''; if (isset($docstring)) { $docstring .= "\n\n".$addendum; } else { $docstring = $addendum; } } if (!isset($docstring)) { return null; } return '
'.$docstring.''; } }