Make WordPress Core


Ignore:
Timestamp:
09/05/2013 04:33:50 PM (11 years ago)
Author:
wonderboymusic
Message:

Remove lingering instances of call time pass-by-reference, limited to instances of callable - use $this instead of &$this.

Props jdgrimes.
See #25160.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tools/i18n/not-gettexted.php

    r25003 r25254  
    6060                continue;
    6161            if ('.php' == substr($item, -4))
    62                 $files[] = $full_item; 
     62                $files[] = $full_item;
    6363            if (is_dir($full_item))
    6464                $files += array_merge($files, NotGettexted::list_php_files($full_item, $files));
     
    100100                    }
    101101                    if ($this->STAGE_START_COMMENT <= $stage && $stage <= $this->STAGE_WHITESPACE_AFTER && '/'.$current_comment_id == $matches[1]) {
    102                         $stage = $this->STAGE_END_COMMENT; 
     102                        $stage = $this->STAGE_END_COMMENT;
    103103                        $this->logmsg('end comment', $current_comment_id);
    104104                        $result .= call_user_func($other_action, $token);
     
    153153            $tokens = token_get_all(file_get_contents($filename));
    154154            $aggregator = $this->make_string_aggregator($global_name, $filename);
    155             $this->walk_tokens($tokens, array(&$this, 'ignore_token'), array(&$this, 'ignore_token'), $aggregator);
     155            $this->walk_tokens($tokens, array($this, 'ignore_token'), array($this, 'ignore_token'), $aggregator);
    156156        }
    157157
     
    197197            if ( strlen($source) > 150000 ) continue;
    198198            $tokens = token_get_all($source);
    199             $new_file = $this->walk_tokens($tokens, $replacer, array(&$this, 'unchanged_token'));
     199            $new_file = $this->walk_tokens($tokens, $replacer, array($this, 'unchanged_token'));
    200200            $f = fopen($filename, 'w');
    201201            fwrite($f, $new_file);
     
    219219            exit(1);
    220220        }
    221         call_user_func_array(array(&$this, $this->commands[$argv[1]]), array_slice($argv, 2));
     221        call_user_func_array(array($this, $this->commands[$argv[1]]), array_slice($argv, 2));
    222222    }
    223223}
Note: See TracChangeset for help on using the changeset viewer.