nlopess         Thu Nov 17 18:04:30 2005 EDT

  Modified files:              
    /phpdoc/scripts     check-references.php file-entities.php.in 
                        process.php spell-checker.php zendapi_protos.php 
  Log:
  PHP 6 compat
  
http://cvs.php.net/diff.php/phpdoc/scripts/check-references.php?r1=1.20&r2=1.21&ty=u
Index: phpdoc/scripts/check-references.php
diff -u phpdoc/scripts/check-references.php:1.20 
phpdoc/scripts/check-references.php:1.21
--- phpdoc/scripts/check-references.php:1.20    Fri Jun 24 10:52:58 2005
+++ phpdoc/scripts/check-references.php Thu Nov 17 18:04:23 2005
@@ -100,7 +100,7 @@
        );
        $return = array();
        for ($i=0; $i < strlen($type_spec); $i++) {
-               $ch = $type_spec{$i};
+               $ch = $type_spec[$i];
                if ($ch != "/" && $ch != "!") {
                        if (!isset($zend_params[$ch])) {
                                echo "! Unknown formatting specifier '$ch' in 
'$type_spec'.\n";
@@ -297,7 +297,7 @@
                                        foreach ($matches2 as $val) {
                                                $number = $val[1] . $val[4];
                                                $operator = strtr($val[2], 
"><", "<>") . $val[3]; // unify to $zend_num_args $operator $number
-                                               switch ($operator{0}) {
+                                               switch ($operator[0]) {
                                                case "=":
                                                case "!":
                                                        if (!$source_arg_count) 
{
http://cvs.php.net/diff.php/phpdoc/scripts/file-entities.php.in?r1=1.40&r2=1.41&ty=u
Index: phpdoc/scripts/file-entities.php.in
diff -u phpdoc/scripts/file-entities.php.in:1.40 
phpdoc/scripts/file-entities.php.in:1.41
--- phpdoc/scripts/file-entities.php.in:1.40    Sat Sep 24 19:28:42 2005
+++ phpdoc/scripts/file-entities.php.in Thu Nov 17 18:04:24 2005
@@ -17,7 +17,7 @@
   |             Gabor Hojtsy <[EMAIL PROTECTED]>                              |
   +----------------------------------------------------------------------+
   
-  $Id: file-entities.php.in,v 1.40 2005/09/24 23:28:42 nlopess Exp $
+  $Id: file-entities.php.in,v 1.41 2005/11/17 23:04:24 nlopess Exp $
 */
 
 /**
@@ -73,7 +73,7 @@
 $refdir = "$out_dir/en/reference";
 $dh = opendir($refdir);
 while ($dir = readdir($dh)) {
-       if ($dir{0} === ".") continue; // ignore system dir entries and hidden 
files
+       if ($dir[0] === ".") continue; // ignore system dir entries and hidden 
files
        if (is_file("$refdir/$dir/reference.xml")
                && !is_file("$refdir/$dir/EXCLUDE")) {
                $dirent = str_replace("_","-",$dir);
@@ -95,7 +95,7 @@
 
     $pecl_dirs = array();
     while($dir = readdir()) { 
-        if($dir{0} === ".") continue; // ignore system dir entries and hidden 
files
+        if($dir[0] === ".") continue; // ignore system dir entries and hidden 
files
         $pecl_dirs[] = $dir;
     }
     
@@ -250,7 +250,7 @@
     // While we can read that directory
     while (($file = readdir($dh)) !== FALSE) {
         // If file name begins with . skip it
-        if ($file{0} == ".") { continue; }
+        if ($file[0] == ".") { continue; }
 
         // If we found a directory, and it's name is not
         // CVS, recursively go into it, and generate entities
@@ -315,7 +315,7 @@
         if ($dh) {
 
             while (($file = readdir($dh)) !== FALSE) {
-                if ($file{0} =="." || $file == "CVS") { continue; }
+                if ($file[0] =="." || $file == "CVS") { continue; }
                 if (is_dir($trans_path."/".$file)) { continue; }
                 
                 // If this is an XML file
http://cvs.php.net/diff.php/phpdoc/scripts/process.php?r1=1.9&r2=1.10&ty=u
Index: phpdoc/scripts/process.php
diff -u phpdoc/scripts/process.php:1.9 phpdoc/scripts/process.php:1.10
--- phpdoc/scripts/process.php:1.9      Wed Aug 25 04:36:32 2004
+++ phpdoc/scripts/process.php  Thu Nov 17 18:04:24 2005
@@ -105,7 +105,7 @@
         //echo "$file\n";
         if (ereg('\.xml$',$file))
             $entries[] = $ffile;
-        if ($file{0} != '.' && is_dir($ffile))
+        if ($file[0] != '.' && is_dir($ffile))
             $entries = array_merge($entries,all_xml_files($ffile));
     }
     closedir($handle);
http://cvs.php.net/diff.php/phpdoc/scripts/spell-checker.php?r1=1.2&r2=1.3&ty=u
Index: phpdoc/scripts/spell-checker.php
diff -u phpdoc/scripts/spell-checker.php:1.2 
phpdoc/scripts/spell-checker.php:1.3
--- phpdoc/scripts/spell-checker.php:1.2        Fri Aug 13 18:33:03 2004
+++ phpdoc/scripts/spell-checker.php    Thu Nov 17 18:04:25 2005
@@ -102,13 +102,13 @@
                 echo "$current_file:" . xml_get_current_line_number($xml) . ": 
$word   (in element $element)\n";
                 do {
                     $response = read_line("Add this word to personal wordlist? 
(yes/no/save): ");
-                    if ($response{0} == 's') {
+                    if ($response[0] == 's') {
                         pspell_save_wordlist($dict);
                         echo "Wordlist saved.\n";
                     }
-                } while ($response{0} != 'y' && $response{0} != 'n');
+                } while ($response[0] != 'y' && $response[0] != 'n');
 
-                if ($response{0} == 'y') {
+                if ($response[0] == 'y') {
                     pspell_add_to_personal($dict, $word);
                     echo "Added '$word' to personal wordlist.\n";
                 }
http://cvs.php.net/diff.php/phpdoc/scripts/zendapi_protos.php?r1=1.8&r2=1.9&ty=u
Index: phpdoc/scripts/zendapi_protos.php
diff -u phpdoc/scripts/zendapi_protos.php:1.8 
phpdoc/scripts/zendapi_protos.php:1.9
--- phpdoc/scripts/zendapi_protos.php:1.8       Tue Aug 30 16:34:05 2005
+++ phpdoc/scripts/zendapi_protos.php   Thu Nov 17 18:04:25 2005
@@ -37,7 +37,7 @@
 
                 // the pointer '*' is usually next to the function name, not 
the type 
                 // TODO what if there is whitespace on both sides of the '*'?
-                while ($function{0} == '*') {
+                while ($function[0] == '*') {
                     $return_type.= "*";
                     $function = substr($function, 1);
                 }
@@ -57,7 +57,7 @@
                         $new_param['type'] = "";
                         $new_param['name'] = $type;
                     } else {
-                        while ($name{0} == '*') {
+                        while ($name[0] == '*') {
                             $type.= "*";
                             $name = substr($name, 1);
                         }

Reply via email to