[PHP-DEV] PHP 5.3.7RC3 Released for Testing
The third and hopefully final release candidate of 5.3.7 was just released for testing and can be downloaded here: https://downloads.php.net/ilia/php-5.3.7RC3.tar.bz2 (md5sum: 0ad46340ca3d4319ab10eac4a3978ae0) https://downloads.php.net/ilia/php-5.3.7RC3.tar.gz (md5sum: eab0329078f74f6c8fe5abcf6943b262) The Windows binaries are available at: http://windows.php.net/qa/ Given the volume of fixes since RC2 it was deemed necessary to make another to ensure that there are no regressions. The intent is that this is the final release candidate before the final release, which if all goes well will follow in 2 weeks. PHP 5.3.7 is focused on improving the stability and security. To ensure that the release is solid, please test this RC against your code base and report any problems that you encounter. To find out what was changed since the last release please refer to the NEWS file found within the archive or on http://svn.php.net/viewvc/php/php-src/tags/php_5_3_7RC3/NEWS?revision=HEAD&view=markup Windows users please mind that we don't provide VS6 builds anymore since PHP 5.3.6. Ilia Alshanetsky -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DEV] PHP 5.4.0alpha2 released
Hello! Stas has packed PHP 5.4.0alpha2 which you can find here: http://downloads.php.net/stas/ The Windows team provides windows binaries which you find here: http://windows.php.net/qa/ Please test it carefully, and report any bugs in the bug system, but only if you have a short reproducable test case. We will have an alpha3 in about 3 to 4 weeks. regards, Stas and David -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DEV] PHP 5.4.0alpha2 released
On 7/14/11 8:32 AM, David Soria Parra wrote: Hello! Stas has packed PHP 5.4.0alpha2 which you can find here: Good stuff. We will have an alpha3 in about 3 to 4 weeks. The wiki currently says it will be on 4 Aug. If this date isn't certain, can you add a note to that effect on the wiki? Thanks, Chris -- Email: christopher.jo...@oracle.com Tel: +1 650 506 8630 Blog: http://blogs.oracle.com/opal/ -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DEV] [VOTE] 5.4 features vote
Hello, Is it possible to add Weak References to this todo list? https://bugs.php.net/bug.php?id=52318 I've been waiting over a year now for this feature. It's a critical part of object relational layer mapping and my framework will be broken until it exists. One of our important customer projects also broke down because my current work around (simply using an array) leaks huge amounts of memory due to automatic instance caching similar to the one in the example I typed down below. I'm also considering switching language since PHP lacks this important OOP concept. There does not yet seem to be an RFC for it so I typed down an example that attempts to look like real-word usage here: http://pastebin.com/pCHVK0L8 I esteimate that it's pretty simple to implement the theoretical "SplWeakArray" in the example I wrote if you have a bit of knowledge about the internals of PHP referencing and garbage collection. See the Java "WeakReference" for conceptual reference. http://download.oracle.com/javase/1.4.2/docs/api/java/lang/ref/WeakReference.html A copy of WeakReference would be a partial solution for me since I rather need a dictionary of id's mapped to objects. I don't want to go trough an array all the time and look for indexes that has been set to NULL. That's the GCs job. Hence the SplWeakArray class. ~Hannes
Re: [PHP-DEV] PHP 5.4.0alpha2 released
On 2011-07-14, Christopher Jones wrote: > > > On 7/14/11 8:32 AM, David Soria Parra wrote: >> Hello! >> >> Stas has packed PHP 5.4.0alpha2 which you can find here: > > Good stuff. > >> We will have an alpha3 in about 3 to 4 weeks. > > The wiki currently says it will be on 4 Aug. If this date isn't > certain, can you add a note to that effect on the wiki? it's the currently proposed date. I didn't want to have it in the announcement so we can adjust it if feel to. -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DEV] [VOTE] 5.4 features vote
Hi! On 7/14/11 8:50 AM, Hannes Landeholm wrote: Hello, Is it possible to add Weak References to this todo list? https://bugs.php.net/bug.php?id=52318 Probably not for 5.4.0. This looks like a thing that needs an RFC and discussion (and implementation of course ;). -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227 -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DEV] [VOTE] 5.4 features vote
Okay, maybe it could be attempted to be squeezed in anyway to 5.4? I really need this feature and apparently others feel the same way. - It would benefit MVC framework design - one of the most common design pattern for web development. - The ticket has been open for over a year now and it has a lot of votes and high score. (High priority.) - It's not especially complex. (Easy to implement.) - It's not a language construct. (Non-controversial.) - It's already implemented in other OOP languages and has been extensivly researched. (Non-controversial.) - It could be implemented by adding a single additional Spl class. (Easy to implement.) ~Hannes On 14 July 2011 20:22, Stas Malyshev wrote: > Probably not for 5.4.0. This looks like a thing that needs an RFC and > discussion (and implementation of course ;). > -- > Stanislav Malyshev, Software Architect > SugarCRM: http://www.sugarcrm.com/ > (408)454-6900 ext. 227 >
Re: [PHP-DEV] [VOTE] 5.4 features vote
Hi! On 7/14/11 11:43 AM, Hannes Landeholm wrote: Okay, maybe it could be attempted to be squeezed in anyway to 5.4? I really need this feature and apparently others feel the same way. We don't even have an RFC on it, let alone consensus & implementation, and we'd have a beta in a little more than a month. This makes timeframe for it very hard. There will be other releases, this is not the last one ;) If we could have RFC and have it agreed upon and have reasonably good implementation in a month, then we could talk about it. But I wouldn't rush it. If it's a stand-alone class, it can also got into .1 etc. release maybe. But I'd start with trunk first. -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227 -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DEV] [VOTE] 5.4 features vote
On 07/14/2011 11:43 AM, Hannes Landeholm wrote: Okay, maybe it could be attempted to be squeezed in anyway to 5.4? I really need this feature and apparently others feel the same way. - It would benefit MVC framework design - one of the most common design pattern for web development. - The ticket has been open for over a year now and it has a lot of votes and high score. (High priority.) - It's not especially complex. (Easy to implement.) - It's not a language construct. (Non-controversial.) - It's already implemented in other OOP languages and has been extensivly researched. (Non-controversial.) - It could be implemented by adding a single additional Spl class. (Easy to implement.) ~Hannes To expand on Stas's statement, you need to start a practical discussion of the feature. This should give examples, show where it will fit in the PHP eco-system, what it will do, and where it will take the language. Once you have received feedback then create an RFC with examples (aka future testcases). And somewhere during this process create a patch or find someone willing to make one. Also see http://news.php.net/php.internals/52812 and https://wiki.php.net/rfc/voting If you're lucky and the idea's good, then you might find it all happens quickly with minimal effort. Otherwise you will need patience and perseverance. Chris -- Email: christopher.jo...@oracle.com Tel: +1 650 506 8630 Blog: http://blogs.oracle.com/opal/ -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DEV] [VOTE] 5.4 features vote
Maybe it could be implemented as a PECL package and then on a future version added to the core of PHP? 2011/7/14 Hannes Landeholm > Okay, maybe it could be attempted to be squeezed in anyway to 5.4? I really > need this feature and apparently others feel the same way. > > - It would benefit MVC framework design - one of the most common design > pattern for web development. > - The ticket has been open for over a year now and it has a lot of votes > and > high score. (High priority.) > - It's not especially complex. (Easy to implement.) > - It's not a language construct. (Non-controversial.) > - It's already implemented in other OOP languages and has been extensivly > researched. (Non-controversial.) > - It could be implemented by adding a single additional Spl class. (Easy to > implement.) > >
[PHP-DEV] weak references
To spare the "5.4 features vote" thread from the off-topic discussion, we can continue here. Hannes Landeholm brought this idea up, see http://news.php.net/php.internals/53956 and http://news.php.net/php.internals/53959 I would suggest that Hannes create an rfc, and add some examples and introduce the weak references in general and how this can be useful, what problems do they solve (it was discussed in the bugreport, but it wasn't clear as far as I can tell from the comments). if I understand this right, Hannes proposed adding a new Spl class(interface?), which can store and retrive a collection of variables without incrementing the refcounts, so they can be freed if they aren't used other than in this collection. Hannes please correct me if I'm wrong somewhere. -- Ferenc Kovács @Tyr43l - http://tyrael.hu -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DEV] Re: $arr = array('Hello', 'world'); $arr();
Will this work: array('foo', 'bar')('arg1', 'arg2') ? On Wed, Jun 8, 2011 at 3:48 PM, Christian Kaps wrote: > On Wed, 8 Jun 2011 15:39:59 +0200, Jordi Boggiano wrote: >> >> On Wed, Jun 8, 2011 at 2:46 PM, Felipe Pena wrote: >>> >>> class foo { >>> public function __construct() { >>> $this->bar = function () { return 1; }; >>> // $this->bar(); // error >>> $x = $this->bar; >>> $x(); // ok >>> >>> $this->bar = array($this, 'baz'); >>> // $this->bar(); // error >>> $x = $this->bar; >>> $x(); // ok >>> } >>> public function baz() { >>> echo 'baz'; >>> } >>> } >> >> What he meant was passing an existing method as a callback if you >> don't invoke it, i.e. passing "$this->bar" instead of array($this, >> "bar"). I don't know how hard it'd be to achieve, but it sounds pretty >> awesome to me. >> >> Cheers > > Yep, just what I meant. > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > > -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DEV] Re: $arr = array('Hello', 'world'); $arr();
2011/7/14 Rune Kaagaard : > Will this work: > > array('foo', 'bar')('arg1', 'arg2') > > ? > No, and it isn't supposed to either. -- Regards, Felipe Pena -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DEV] deprecating ext/mysql
On 07/10/2011 12:03 PM, Philip Olson wrote: Greetings PHP geeks, Don't panic! This is not a proposal to add errors or remove this popular extension. Not yet anyway, because it's too popular to do that now. The documentation team is discussing the database security situation, and educating users to move away from the commonly used ext/mysql extension is part of this. This proposal only deals with education, and requests permission to officially convince people to stop using this old extension. This means: - Add notes that refer to it as deprecated - Recommend and link alternatives - Include examples of alternatives There are two alternative extensions: pdo_mysql and mysqli, with PDO being the PHP way and main focus of future endeavors. Right? Please don't digress into the PDO v2 fiasco here. What this means to ext/mysql: - Softly deprecate ext/mysql with education (docs) starting today - Not adding E_DEPRECATED errors in 5.4, but revisit for 5.5/6.0 - Add pdo_mysql examples within the ext/mysql docs that mimic the current examples, but occasionally introduce features like prepared statements - Focus energy on cleaning up the pdo_mysql and mysqli documentation - Create a general "The MySQL situation" document that explains the situation The PHP community has been recommending alternatives for several years now, so hopefully this won't be a new concept or shock to most users. Regards, Philip A-frickin'-men! :-) Just today I was talking to a new developer in #PHP in IRC who had code with mysql_* calls in it. I don't know where he found them, but I told him to put them back where he found them right away and use PDO instead. That people are still learning ext/mysql in this day and age is quite sad. There's millions of lines of code out there we can't break yet, but we can absolutely structure documentation so that we don't produce even more PHP developers who mistakenly think that mysql_query() is a good idea. +1 --Larry Garfield -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php