[Momonga-devel.ja:02819] PHP5


大垣です。

headにPHP5をコミットしました。

http://www.php.net/ChangeLog-5.php
http://www.php.net/manual/en/language.oop5.php
http://www.php.net/manual/en/faq.migration5.php
http://zend.com/php5/index.php

PHP5はinterface, private/protected, final, reflection等
OOP機能が大幅に強化されています。オブジェクトもハンドルで
処理されるように変更され違和感無くオブジェクトを操作可能に
なっています。

例1:
オブジェクトの実体を代入したい場合、$obj_foo = &$obj_bar;
と記述せずに普通に $obj_foo=$obj_bar と普通に記述可能になっ
た。(オブジェクトの複製にはcloneを利用します)

例2:
$obj_foo->some_method()->other_method(); の様なオブジェクト
参照が可能になった。

詳しくはPHP関連のWebサイトを御覧下さい。

PHP4用に書かれたスクリプトの多くが動作しますが、オブジェクトを
使用したスクリプトはパッチが必要な場合があります。pukiwikiは
$this = new Hoge()などとしていたためPHP5ではエラーになりまし
た。このためPHP5用のパッチを追加しています。

phpbb, squirrelmailはまだ動作確認していませんが、問題がある
可能性が高いです。パッチ、歓迎します。

PECLモジュールは別パッケージとして作成する予定です。現在は
kakashi, chasen等のPECLモジュールが無い状態です。

以下にchangelogの一部を抜粋します。

  Configuration is based on php.ini-recommended.
  Script error will not displayed but logged to /var/log/php-error.log
  PHP4 compatibility mode if off by default.
     zend.ze1_compatibility_mode = Off
  Call time pass by reference is off by default.
  Short open tag (<?) is disabled by default. Use <?php instead.
     short_open_tag = Off
  All PECL modules (e.g. kakashi, chasen) are disabled for now.
  ming support is disabled for now. (Need newer jaming(ming) but it's not released yet)
  Session module uses SHA1 instead of MD5.
  Session data is stored to /var/state/php.
  Error reporting E_ALL by default.
  DOM support is built in. (php-domxml is obsolete)
  Added ini file support for dba module.
  Added fam, tidy module support.
  SQLite support is built in. UTF-8 support is enabled.
  MySQLi module is not included. (MySQL 4.1 is required for mysqli)
  Crack module is removed. (It may be added as PECL module)
  Enabled GD JIS support
- List of unsupported modules
   FrontBase
   FDF
   Informix
   Ingres II
   InterBase
   IRCG
   MCVE
   msession
   msql
   mssql
   mysqli
   Oracle-OCI7
   Oracle-OCI8
   Adabas D
   SAP DB
   Solid
   IBM DB2
   Empress
   Birdstep
   Easysoft OOB
   DBMaker
   Ovrimos SQL
   Verisign Payflow Pro
   Hyperwave

--
Yasuo Ohgaki