5
5
6
6
class PHPCtags
7
7
{
8
- const VERSION = '0.8.1 ' ;
8
+ const VERSION = '0.9.0 ' ;
9
9
10
10
private $ mFile ;
11
11
@@ -323,14 +323,16 @@ private function render($structure)
323
323
if (in_array ('s ' , $ this ->mOptions ['fields ' ]) && !empty ($ struct ['scope ' ])) {
324
324
// $scope, $type, $name are current scope variables
325
325
$ scope = array_pop ($ struct ['scope ' ]);
326
- list ($ type , $ name ) = each ($ scope );
326
+ $ type = key ($ scope );
327
+ $ name = current ($ scope );
327
328
switch ($ type ) {
328
329
case 'class ' :
329
330
// n_* stuffs are namespace related scope variables
330
331
// current > class > namespace
331
332
$ n_scope = array_pop ($ struct ['scope ' ]);
332
333
if (!empty ($ n_scope )) {
333
- list ($ n_type , $ n_name ) = each ($ n_scope );
334
+ $ n_type = key ($ n_scope );
335
+ $ n_name = current ($ n_scope );
334
336
$ s_str = 'class: ' . $ n_name . '\\' . $ name ;
335
337
} else {
336
338
$ s_str = 'class: ' . $ name ;
@@ -340,10 +342,12 @@ private function render($structure)
340
342
// c_* stuffs are class related scope variables
341
343
// current > method > class > namespace
342
344
$ c_scope = array_pop ($ struct ['scope ' ]);
343
- list ($ c_type , $ c_name ) = each ($ c_scope );
345
+ $ c_type = key ($ c_scope );
346
+ $ c_name = current ($ c_scope );
344
347
$ n_scope = array_pop ($ struct ['scope ' ]);
345
348
if (!empty ($ n_scope )) {
346
- list ($ n_type , $ n_name ) = each ($ n_scope );
349
+ $ n_type = key ($ n_scope );
350
+ $ n_name = current ($ n_scope );
347
351
$ s_str = 'method: ' . $ n_name . '\\' . $ c_name . ':: ' . $ name ;
348
352
} else {
349
353
$ s_str = 'method: ' . $ c_name . ':: ' . $ name ;
0 commit comments