@@ -98,14 +98,14 @@ public function printClass(ClassType $class, PhpNamespace $namespace = null): st
98
98
foreach ($ class ->getConstants () as $ const ) {
99
99
$ consts [] = Helpers::formatDocComment ((string ) $ const ->getComment ())
100
100
. ($ const ->getVisibility () ? $ const ->getVisibility () . ' ' : '' )
101
- . 'const ' . $ const ->getName () . ' = ' . Helpers:: dump ($ const ->getValue ()) . "; \n" ;
101
+ . 'const ' . $ const ->getName () . ' = ' . $ this -> dump ($ const ->getValue ()) . "; \n" ;
102
102
}
103
103
104
104
$ properties = [];
105
105
foreach ($ class ->getProperties () as $ property ) {
106
106
$ properties [] = Helpers::formatDocComment ((string ) $ property ->getComment ())
107
107
. ($ property ->getVisibility () ?: 'public ' ) . ($ property ->isStatic () ? ' static ' : '' ) . ' $ ' . $ property ->getName ()
108
- . ($ property ->getValue () === null ? '' : ' = ' . Helpers:: dump ($ property ->getValue ()))
108
+ . ($ property ->getValue () === null ? '' : ' = ' . $ this -> dump ($ property ->getValue ()))
109
109
. "; \n" ;
110
110
}
111
111
@@ -194,6 +194,12 @@ protected function indent(string $s): string
194
194
}
195
195
196
196
197
+ protected function dump ($ var ): string
198
+ {
199
+ return Helpers::dump ($ var );
200
+ }
201
+
202
+
197
203
protected function printUses (PhpNamespace $ namespace ): string
198
204
{
199
205
$ name = $ namespace ->getName ();
@@ -225,7 +231,7 @@ protected function printParameters($function, ?PhpNamespace $namespace): string
225
231
. ($ param ->isReference () ? '& ' : '' )
226
232
. ($ variadic ? '... ' : '' )
227
233
. '$ ' . $ param ->getName ()
228
- . ($ param ->hasDefaultValue () && !$ variadic ? ' = ' . Helpers:: dump ($ param ->getDefaultValue ()) : '' );
234
+ . ($ param ->hasDefaultValue () && !$ variadic ? ' = ' . $ this -> dump ($ param ->getDefaultValue ()) : '' );
229
235
}
230
236
231
237
return strlen ($ tmp = implode (', ' , $ params )) > Helpers::WRAP_LENGTH && count ($ params ) > 1
0 commit comments