Re: [PHP-DEV] [PATCH] [RFC] Closures and lambda functions in PHP

2008-06-24 Thread Kalle Sommer Nielsen
Hey How are we going to deal with Closures in class properties, like: class PHP { public $closure; public function __construct($callback) { $this-closure = $callback; } public function closure() { echo

Re: [PHP-DEV] [PATCH] [RFC] Closures and lambda functions in PHP

2008-06-24 Thread troels knak-nielsen
On Tue, Jun 24, 2008 at 9:19 AM, Kalle Sommer Nielsen [EMAIL PROTECTED] wrote: Another subject I would like to see now the closures has been brought up again is, how about adding type hinting in method/function prototypes: function call(function $callback) { $callback(); } Good

[PHP-DEV] Re: Fw: [PHP-CVS] cvs: php-src(PHP_5_3) /win32/build confutils.js

2008-06-24 Thread Jani Taskinen
Someone sent some patch long time ago to make it use PCRE instead.. I have no idea of it either. --Jani Steph Fox [EMAIL PROTECTED] kirjoitti: Hey Jani, You can run but you can't hide ;) I'm assuming this is down to you, since you moved ereg. I won't even pretend to understand

[PHP-DEV] Re: cvs: php-src(PHP_5_3) /ext/standard string.c

2008-06-24 Thread Sebastian Bergmann
Dmitry Stogov wrote: dmitry Tue Jun 24 06:07:08 2008 UTC Modified files: (Branch: PHP_5_3) /php-src/ext/standard string.c Log: Fixed strtolower/strtoupper to not modify the passed argument Was this patch required because of an issue introduced in revision

Re: [PHP-DEV] Re: cvs: php-src(PHP_5_3) /ext/standard string.c

2008-06-24 Thread Sebastian Bergmann
Sebastian Bergmann wrote: Was this patch required because of an issue introduced in revision 1.445.2.14.2.69.2.23 of the file (the parameter parsing API update)? If so, there might be more issues of a similar kind in there as PHPUnit breaks starting with revision 1.445.2.14.2.69.2.23 of

Re: [PHP-DEV] OpenSSL and Phar

2008-06-24 Thread Steph Fox
Hi Greg, I must be going crazy. Is there an actual problem that needs solving? Yep, solved yesterday. You're saying that a user who improperly installs php_openssl.dll (i.e. does not follow instructions and set up ssleay.dll and libeay.dll) should magically be able to use phar with

Re: [PHP-DEV] OpenSSL and Phar

2008-06-24 Thread Pierre Joye
On Tue, Jun 24, 2008 at 2:46 AM, Greg Beaver [EMAIL PROTECTED] wrote: I must be going crazy. Is there an actual problem that needs solving? You're saying that a user who improperly installs php_openssl.dll (i.e. does not follow instructions and set up ssleay.dll and libeay.dll) should

Re: [PHP-DEV] OpenSSL and Phar

2008-06-24 Thread Steph Fox
Pierre, I must be going crazy. Is there an actual problem that needs solving? You're saying that a user who improperly installs php_openssl.dll (i.e. does not follow instructions and set up ssleay.dll and libeay.dll) should magically be able to use phar with openssl? Why? You are not

Re: [PHP-DEV] OpenSSL and Phar

2008-06-24 Thread Pierre Joye
Hi, Please top to make easy problems an endless pain please. And stop to mix every topics you can think about in every single discussions. Also it would be nice if you get cooler and stop to harass me on every single reply or commit, get a life, do something, whatever helps but stop to harass

RE: [PHP-DEV] New flame

2008-06-24 Thread Derick Rethans
On Mon, 16 Jun 2008, Andi Gutmans wrote: From: Lukas Kahwe Smith [mailto:[EMAIL PROTECTED] I was under impression parser multibyte support wasn't yet fixed. Was it? Maybe we should decide if this a show stopper or not. From my understanding we still do not have any example of

Re: [PHP-DEV] [RFC] Starting 5.3

2008-06-24 Thread Milan Babuskov
Pierre Joye wrote: You don't have to be a windows pro as long as you can test it on windows. The main problem now is that we had no maintainer to take care of the bugs (there is bugs), to valid a release (sources or binary), etc. Are you (still) interested? :) Yes. I'll report back when I

Re: [PHP-DEV] [RFC] Starting 5.3

2008-06-24 Thread Milan Babuskov
Hi, Stanislav Malyshev wrote: In general, building PHP on windows should be as easy as on Unix, not requiring any special knowledge of the tools, meaning: 1. Get environment with MSVC set up 2. Get external libraries (recommended to put them in same upper-level dir as php checkout) 3. Run

Re: [PHP-DEV] New flame

2008-06-24 Thread Stefan Esser
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 This is used when reading scripts that are in encodings like Shift-JIS which is very common in Japan. In any case, I have tried to get involvement from some people I know over there without much success. I've asked around a bit as well with

Re: [PHP-DEV] New flame

2008-06-24 Thread Lukas Kahwe Smith
On 24.06.2008, at 16:10, Derick Rethans wrote: On Mon, 16 Jun 2008, Andi Gutmans wrote: From: Lukas Kahwe Smith [mailto:[EMAIL PROTECTED] I was under impression parser multibyte support wasn't yet fixed. Was it? Maybe we should decide if this a show stopper or not. From my understanding

Re: [PHP-DEV] New flame

2008-06-24 Thread Lukas Kahwe Smith
On 24.06.2008, at 16:21, Stefan Esser wrote: If PHP 5.3 drops this feature it might close some multibyte security problems. However this also means that all those Japanese/Chinese/Korean/Taiwanese/... multibyte scripts will not run anymore. This forces systems to stay on PHP 5.2 which will

Re: [PHP-DEV] New flame

2008-06-24 Thread Stefan Esser
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hello Lukas, As such the conclusion can only be that investing any time in readding this feature would be a bad idea. If anyone actually uses this feature they will have to come out of the woodwork now or when 5.3 is out. At this point we might

Re: [PHP-DEV] New flame

2008-06-24 Thread Paweł Stradomski
W liście Stefan Esser z dnia wtorek 24 czerwca 2008: The problem here is that newer Asian systems will use UTF-8 (except those nations using characters not possible in utf-8) and therefore the customers of the PHP developers (on this list) will not need that support. UTF-8 can express all

Re: [PHP-DEV] simple solution to another namespace conundrum?

2008-06-24 Thread Derick Rethans
On Fri, 20 Jun 2008, Gregory Beaver wrote: The user is obviously intentionally creating a DateTime class, and doesn't care about the internal classname in this script. The attached patch against PHP_5_3 would fix the issue by eliminating the check for conflict with CG(class_table) in the

Re: [PHP-DEV] simple solution to another namespace conundrum?

2008-06-24 Thread Alexey Zakhlestin
On Tue, Jun 24, 2008 at 6:36 PM, Derick Rethans [EMAIL PROTECTED] wrote: On Fri, 20 Jun 2008, Gregory Beaver wrote: The user is obviously intentionally creating a DateTime class, and doesn't care about the internal classname in this script. The attached patch against PHP_5_3 would fix the

Re: [PHP-DEV] New flame

2008-06-24 Thread Asbjørn Sloth Tønnesen
Paweł Stradomski wrote: W liście Stefan Esser z dnia wtorek 24 czerwca 2008: The problem here is that newer Asian systems will use UTF-8 (except those nations using characters not possible in utf-8) and therefore the customers of the PHP developers (on this list) will not need that support.

Re: [PHP-DEV] simple solution to another namespace conundrum?

2008-06-24 Thread Derick Rethans
On Tue, 24 Jun 2008, Alexey Zakhlestin wrote: On Tue, Jun 24, 2008 at 6:36 PM, Derick Rethans [EMAIL PROTECTED] wrote: On Fri, 20 Jun 2008, Gregory Beaver wrote: The user is obviously intentionally creating a DateTime class, and doesn't care about the internal classname in this script.

Re: [PHP-DEV] simple solution to another namespace conundrum?

2008-06-24 Thread Rasmus Lerdorf
Derick Rethans wrote: On Tue, 24 Jun 2008, Alexey Zakhlestin wrote: On Tue, Jun 24, 2008 at 6:36 PM, Derick Rethans [EMAIL PROTECTED] wrote: On Fri, 20 Jun 2008, Gregory Beaver wrote: The user is obviously intentionally creating a DateTime class, and doesn't care about the internal

Re: [PHP-DEV] New flame

2008-06-24 Thread Edward Z. Yang
Asbjørn Sloth Tønnesen wrote: Some some minor inconsistencies, between Shift-JIS and Unicode. http://en.wikipedia.org/wiki/Unicode#Mapping_to_legacy_character_sets And I say good riddance! The yen/backslash conflation has given me plenty a PITA in the past. -- Edward Z. Yang

Re: [PHP-DEV] simple solution to another namespace conundrum?

2008-06-24 Thread Lukas Kahwe Smith
On 24.06.2008, at 16:52, Derick Rethans wrote: On Tue, 24 Jun 2008, Alexey Zakhlestin wrote: On Tue, Jun 24, 2008 at 6:36 PM, Derick Rethans [EMAIL PROTECTED] wrote: On Fri, 20 Jun 2008, Gregory Beaver wrote: The user is obviously intentionally creating a DateTime class, and doesn't

Re: [PHP-DEV] simple solution to another namespace conundrum?

2008-06-24 Thread James Dempster
I find it interesting that we could quite possibly get just as many clashes with namespaced code. Of course it comes down to how well the developer implements there code. It's almost like namespace is just a method of aliasing long class names. On Tue, Jun 24, 2008 at 4:38 PM, Lukas Kahwe Smith

Re: [PHP-DEV] LSB forward_static_call()

2008-06-24 Thread Stanislav Malyshev
Hi! in my ActiveRecord, table for DepartmentUsers would actually exist ;) Even worse. All the data is in the Users table, DepartmentUsers is just a functionality extension. So you'll be operating on wrong data. I am just looking for consistency. I am expecting get_called_class() to work

Re: [PHP-DEV] [RFC] Starting 5.3

2008-06-24 Thread Milan Babuskov
Rob Richards wrote: Moving this to the windows list. I'm having problems to post on it. Care to forward? Make sure you are using the Visual Studio command prompt as it will setup your env for you (all the paths, etc...). I am. As I wrote, I can compile wxWidgets and FlameRobin without any

Re: [PHP-DEV] [RFC] Starting 5.3

2008-06-24 Thread Milan Babuskov
Rob Richards wrote: Moving this to the windows list. I'm having problems to post on it via newsgroup interface, and I don't know how to subscribe to the mailing list, since it is not listed here: http://www.php.net/mailing-lists.php Is there a way to contact someone to add it? Thanks, --

Re: [PHP-DEV] LSB forward_static_call()

2008-06-24 Thread Janusz Lewandowski
?php class A { function mA() { echo get_class($this); } static function mB() { echo get_called_class(); } } class B extends A { function mA() { parent::mA(); } static

Re: [PHP-DEV] [PATCH] [RFC] Closures and lambda functions in PHP

2008-06-24 Thread Wez Furlong
Just to chime in on this thread; I like your implementation and (after reading through all the other comments so far), prefer the lexical keyword to import variables. As I've said before, the closure aspect of this is the hardest to gel into PHP, which deliberately avoids inheriting scopes.

Re: [PHP-DEV] LSB forward_static_call()

2008-06-24 Thread Stanislav Malyshev
Currently, this will output BA. You can't tell me, that it is consistent. Sure, it's very inconsistent. Also, when you do 2+3, the result is 5, and when you do 2*3, result is 6. It's very inconsistent too. Let's change + to do multiplication, so it'd be consistent. Why on earth different

Re: [PHP-DEV] LSB forward_static_call()

2008-06-24 Thread Janusz Lewandowski
?php class A { function mA() { $this-nA(); } static function mB() { self::nB(); } } class B extends A { function mA() { parent::mA(); } static function mB() {

Re: [PHP-DEV] LSB forward_static_call()

2008-06-24 Thread Stanislav Malyshev
Hi! Most people will think, that it will output AB. But currently in PHP 5.2 (I don't have PHP 5.3 to test it) it will output: Most people will know (if really trying to understand and not trying to appear as they do not understand simple things in order to advance their point) that self is

Re: [PHP-DEV] [PATCH] [RFC] Closures and lambda functions in PHP

2008-06-24 Thread Lukas Kahwe Smith
On 24.06.2008, at 18:55, Wez Furlong wrote: I'm +1 for inclusion of this into the next release of PHP (post 5.3), and like Andrei, would love there to be a first class callable type for dynamic invocation of regular functions and methods. Just a side note about the timing. I know some

Re: [PHP-DEV] LSB forward_static_call()

2008-06-24 Thread Etienne Kneuss
Hello, With such example, using Users:: over parent:: actually makes sense as your intent is to request something strictly related to Users, and you're not expecting any inheritance. Sure, introducing a difference is not a perfect solution, but the general feeling is that it's the best at hand.

Re: [PHP-DEV] LSB forward_static_call()

2008-06-24 Thread Stanislav Malyshev
Hi! No need to argue over and over, I'll produce a patch based on the (probably) outdated one done by Mike and have it committed if no new strong feelings against it raises. I must be missing something in this discussion concept. So it goes like this: I will make a patch and commit - No,

Re: [PHP-DEV] LSB forward_static_call()

2008-06-24 Thread Etienne Kneuss
Hello, you're the only one disagreeing here, in this thread everybody is in favor of that change except you, and your arguments are: 1) this difference is bad 2) no problem with functions For which I've (along with others) already argued that: 1.1) some difference is already felt by regular

Re: [PHP-DEV] LSB forward_static_call()

2008-06-24 Thread Ryan Panning
Janusz Lewandowski wrote: ?php class A { function mA() { $this-nA(); } static function mB() { self::nB(); } } class B extends A { function mA() { parent::mA(); }

Re: [PHP-DEV] [RFC] Starting 5.3

2008-06-24 Thread Ryan Panning
Milan Babuskov wrote: Rob Richards wrote: Moving this to the windows list. I'm having problems to post on it via newsgroup interface, and I don't know how to subscribe to the mailing list, since it is not listed here: http://www.php.net/mailing-lists.php Is there a way to contact someone

Re: [PHP-DEV] [RFC] Starting 5.3

2008-06-24 Thread Lester Caine
Ryan Panning wrote: Milan Babuskov wrote: Rob Richards wrote: Moving this to the windows list. I'm having problems to post on it via newsgroup interface, and I don't know how to subscribe to the mailing list, since it is not listed here: http://www.php.net/mailing-lists.php Is there a