Re: [PHP-DEV] [VOTE] Weak References

2011-08-04 Thread Lars Schultz
Am 05.08.2011 08:07, schrieb Rasmus Lerdorf: Ticks have been in PHP forever. See http://www.php.net/manual/en/control-structures.declare.php#control-structures.declare.ticks woha! interesting read. thanks:) -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://w

Re: [PHP-DEV] [VOTE] Weak References

2011-08-04 Thread Rasmus Lerdorf
On 08/04/2011 11:00 PM, Lars Schultz wrote: > Could you explain ticks?...to me a tick is a nasty little creature that > bites and gives you infections;) Ticks have been in PHP forever. See http://www.php.net/manual/en/control-structures.declare.php#control-structures.declare.ticks -Rasmus -- PH

Re: [PHP-DEV] [VOTE] Weak References

2011-08-04 Thread Lars Schultz
Am 04.08.2011 23:19, schrieb Chris Stockton: I myself oppose WeakReference in java and I do not see my opinion changing for PHP ... unfortunately I think WeakReference's are even nastier in PHP because of it's error handling. You see it is very common when weak references are used in java too fol

Re: [PHP-DEV] RSS channel or maillist for bugs

2011-08-04 Thread Sokolov Evgeniy
Thanks you! I try find it on http://php.net/mailing-lists.php, but there are no this maillists. 2011/8/4 Ferenc Kovacs > On Thu, Aug 4, 2011 at 6:51 PM, Sokolov Evgeniy wrote: > > Hi All. > > > > I can't find RSS channel or maillist for https://bugs.php.net. If it > exists? > > > > the genera

[PHP-DEV] TameJS syntax for Async/Parallel execution in PHP

2011-08-04 Thread Raymond Irving
Hello, I came across this little library called TameJS (http://tamejs.org/) and fell in love with the it's syntax. This had me thinking if it was possible to add such features to a PHP CLI (or web app): fetchAll(); // do something here ?> The "await" keyword marks a section of code that depends

[PHP-DEV] Re: changes in the bugsweb

2011-08-04 Thread Ferenc Kovacs
On Tue, Jul 19, 2011 at 2:03 PM, Ferenc Kovacs wrote: > Hi guys. > > a few days ago I did a little modifications on > web/php-bugs/trunk/include/php_versions.php so now it fetch the > version information from http://qa.php.net/api.php and > http://www.php.net/releases/index.php > so if everything

[PHP-DEV] PHP 5.4alpha3

2011-08-04 Thread David Soria Parra
Hello! Stas has packed PHP 5.4.0alpha3 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 reprod

Re: [PHP-DEV] Re: An implementation of a short syntax for closures

2011-08-04 Thread Stas Malyshev
Hi! On 8/4/11 2:02 PM, Jezz Goodwin wrote: Your argument goes back to whether or not PHP should have short-hand lambdas in general. It's looking like the majority of people think it shouldn't. And really, PHP doesn't need more cryptic syntax. There are many things that PHP does need (like peo

Re: [PHP-DEV] [VOTE] Weak References

2011-08-04 Thread Chris Stockton
Hello, On Thu, Aug 4, 2011 at 1:53 PM, Ferenc Kovacs wrote: > so as I see you didn't really addressed the proposed use-case of the > Weak References, just stated what everybody is aware of: one can cache > and free objects "manually" without the need of Weak References. > and while that is true,

Re: [PHP-DEV] Re: An implementation of a short syntax for closures

2011-08-04 Thread Jezz Goodwin
Haha, yes indeed. In fact my Thunderbird was changing them to sad smileys until I disabled emoticons! Colon is one of many possibilities. Your argument goes back to whether or not PHP should have short-hand lambdas in general. It's looking like the majority of people think it shouldn't. O

Re: [PHP-DEV] [VOTE] Weak References

2011-08-04 Thread Ferenc Kovacs
On Thu, Aug 4, 2011 at 6:35 PM, Stas Malyshev wrote: > Hi! > On 8/4/11 5:34 AM, Lars Schultz wrote: >>> >>> Do not keep object references, keep object IDs. This would make your >>> code a bit more verbose and a bit slower, but weak refs would >>> essentially do the same anyway. >> >> This is like

Re: [PHP-DEV] Re: An implementation of a short syntax for closures

2011-08-04 Thread Johannes Schlüter
On Thu, 2011-08-04 at 21:17 +0100, Jezz Goodwin wrote: > :($x)=>$x+1; ":(" looks quite sad. I also assume you know that : is a division. In a more complex situation this might, on first sight, be mistaken as a division by $x or such. Mind that a line of code typically is read way more often than

Re: [PHP-DEV] Re: An implementation of a short syntax for closures

2011-08-04 Thread Jezz Goodwin
On 04/08/2011 21:42, Jérémy Poulain wrote: Hi every one, This message is also my first one. I've been following internals for few weeks now. I really don't think adding more short syntax would be a good idea, at least this one. PHP is a very popular language for many reasons, it's C-like, easy

Re: [PHP-DEV] Re: An implementation of a short syntax for closures

2011-08-04 Thread Jérémy Poulain
Hi every one, This message is also my first one. I've been following internals for few weeks now. I really don't think adding more short syntax would be a good idea, at least this one. PHP is a very popular language for many reasons, it's C-like, easy readable. We all had to read some code made

Re: [PHP-DEV] Re: An implementation of a short syntax for closures

2011-08-04 Thread Jezz Goodwin
In terms of thinking about typos, I'm sure there would be a solution to making pretty robust short hand lambdas. I think a more valid discussion would be whether PHP should have a short hand lamda notation. A lot of talk on here is against there even being a short-hand version, whatever syntax

Re: [PHP-DEV] Re: An implementation of a short syntax for closures

2011-08-04 Thread Sebastian Krebs
Just two examples, why I think, this is a not a good idea. Simple typos can produce hard to track errors. Its just confusing $x = 4; $y = ($x);{ return $x*2; } // and $x = 4; $x = ($x) { $y = $x*2; } On 04.08.2011 21:52, Jezz Goodwin wrote: Hello PHP Internals, This is my first m

Re: [PHP-DEV] Re: An implementation of a short syntax for closures

2011-08-04 Thread Jezz Goodwin
On 04/08/2011 21:00, Matthew Weier O'Phinney wrote: On 2011-08-04, Jezz Goodwin wrote: --060805070009050707030403 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Hello PHP Internals, This is my first message to the list. I've been readin

[PHP-DEV] Re: An implementation of a short syntax for closures

2011-08-04 Thread Matthew Weier O'Phinney
On 2011-08-04, Jezz Goodwin wrote: > --060805070009050707030403 > Content-Type: text/plain; charset=ISO-8859-1; format=flowed > Content-Transfer-Encoding: 7bit > > Hello PHP Internals, > > This is my first message to the list. I've been reading via the archive > since I read the 5.4RC

[PHP-DEV] Re: An implementation of a short syntax for closures

2011-08-04 Thread Jezz Goodwin
Hello PHP Internals, This is my first message to the list. I've been reading via the archive since I read the 5.4RC1 announcement. (Keep up the great work guys - I'm loving the new stuff) Up until now I haven't had anything to say that wasn't already being talked about, but the topic of shor

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Paul Dragoonis
On Thu, Aug 4, 2011 at 7:54 PM, dukeofgaming wrote: > On Thu, Aug 4, 2011 at 1:47 PM, Gwynne Raskind wrote: > >> On Thu, Aug 4, 2011 at 09:12, Antony Dovgal wrote: >> >>>  Btw, am I the only one to whom the proposed syntax seems kinda >> >>> hieroglyphic? >> >> No. I don't see at all why we need

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread dukeofgaming
On Thu, Aug 4, 2011 at 1:47 PM, Gwynne Raskind wrote: > On Thu, Aug 4, 2011 at 09:12, Antony Dovgal wrote: > >>> Btw, am I the only one to whom the proposed syntax seems kinda > >>> hieroglyphic? > >> No. I don't see at all why we need this, just like I don't see why we > >> needed an alternativ

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Gwynne Raskind
On Thu, Aug 4, 2011 at 09:12, Antony Dovgal wrote: >>>  Btw, am I the only one to whom the proposed syntax seems kinda >>> hieroglyphic? >> No. I don't see at all why we need this, just like I don't see why we >> needed an alternative (short) syntax for arrays. This kind of syntax >> additions tha

Re: [PHP-DEV] Re: json_encode option for not escaping unnecessary character

2011-08-04 Thread Александр Москалёв
Hi, Scott. I wrote you on scott...@php.net. This patch - my first work on C language. I write it becouse people advised me write patch for fast feature adding. I also tried add minimal changes. If you spend a little time to check and fix my patch, I would be very thankful to you. With regards, Ale

Re: [PHP-DEV] RSS channel or maillist for bugs

2011-08-04 Thread Ferenc Kovacs
On Thu, Aug 4, 2011 at 6:51 PM, Sokolov Evgeniy wrote: > Hi All. > > I can't find RSS channel or maillist for https://bugs.php.net. If it exists? > the general mailing list for bugs is php-b...@lists.php.net the rss feed for it is http://news.php.net/group.php?group=php.bugs&format=rss some bug

[PHP-DEV] Re: [PATCH] fix imap_mail actually use the rpath option

2011-08-04 Thread Keloran
Yeah it does need cleaning up, didn't know about the new mail options, main reason I did it was because the function has had the option since 2004, but it's never actually used it On Thursday, August 4, 2011, Johannes Schlüter wrote: > Hi, > > few comments just from reading the patch, not the ful

[PHP-DEV] RSS channel or maillist for bugs

2011-08-04 Thread Sokolov Evgeniy
Hi All. I can't find RSS channel or maillist for https://bugs.php.net. If it exists?

Re: [PHP-DEV] 5.3.7 is there a RC5 coming soon?

2011-08-04 Thread Johannes Schlüter
This seems to be a build, not an code issue. So this should be fixed by a build independently from RC or final. Pierre can confirm. johannes On Thu, 2011-08-04 at 09:36 -0700, James Yu wrote: > I found there's critical bug fixed after RC4 > > https://bugs.php.net/bug.php?id=55356 > > SSL didn

Re: [PHP-DEV] [VOTE] Weak References

2011-08-04 Thread Lars Schultz
Am 04.08.2011 18:35, schrieb Stas Malyshev: No, it's not even remotely like that. Using one intermediary function and doing the DB call is orders of magnitude apart. You asked how you can solve the problem, I showed you how. You can claim you don't like the solution, that's fine, everybody has hi

Re: [PHP-DEV] Re: json_encode option for not escaping unnecessary character

2011-08-04 Thread Scott MacVicar
Never got the email, will look today at it. Doesn't quite match our coding standards from the first glance. S On 4 Aug 2011, at 09:17, Александ Москалёв wrote: > I write to omar (ext author) and scottmac (bug owner) and not received > a reply from they. > > Can someone else check this patch, p

Re: [PHP-DEV] [PATCH] fix imap_mail actually use the rpath option

2011-08-04 Thread Johannes Schlüter
Hi, few comments just from reading the patch, not the full context, not testing it: On Thu, 2011-08-04 at 16:30 +0100, Keloran wrote: > Index: ext/imap/php_imap.c > === > --- ext/imap/php_imap.c (revision 314217) > +++ ext/imap/php_i

Re: [PHP-DEV] [VOTE] Weak References

2011-08-04 Thread Stas Malyshev
Hi! On 8/4/11 5:34 AM, Lars Schultz wrote: Do not keep object references, keep object IDs. This would make your code a bit more verbose and a bit slower, but weak refs would essentially do the same anyway. This is like saying: do not use objects at all and use the DB for storage. verbosity and

Re: [PHP-DEV] 5.3.7 is there a RC5 coming soon?

2011-08-04 Thread James Yu
I found there's critical bug fixed after RC4 https://bugs.php.net/bug.php?id=55356 SSL didn't work properly in RC4. Thanks, James On Thu, Aug 4, 2011 at 7:10 AM, Ilia Alshanetsky wrote: > Unless something changes, I think we are going to go from RC4 to final > release. > > On Wed, Aug 3, 201

Re: [PHP-DEV] [PATCH] fix imap_mail actually use the rpath option

2011-08-04 Thread Keloran
cool, thanks that patch is for 5.4 (since the line nums changed from 5.3-5.4, On Thu, Aug 4, 2011 at 5:19 PM, Pierre Joye wrote: > I have now attached the patch to the issue: > https://bugs.php.net/bug.php?id=30688 > > On Thu, Aug 4, 2011 at 6:07 PM, Keloran wrote: > > patch attached > > > > O

Re: [PHP-DEV] [PATCH] fix imap_mail actually use the rpath option

2011-08-04 Thread Pierre Joye
I have now attached the patch to the issue: https://bugs.php.net/bug.php?id=30688 On Thu, Aug 4, 2011 at 6:07 PM, Keloran wrote: > patch attached > > On Thu, Aug 4, 2011 at 4:39 PM, Pierre Joye wrote: >> >> hi, >> >> Can you attach this patch to the bug please? >> >> Thanks for your work! >> >>

[PHP-DEV] Re: json_encode option for not escaping unnecessary character

2011-08-04 Thread Александр Москалёв
I write to omar (ext author) and scottmac (bug owner) and not received a reply from they. Can someone else check this patch, please? With regards, Alexander Moskaliov ir...@irker.net 2011/7/25 Александр Москалёв : > Hello. Can someone check my patch in this > request https://bugs.php.net/bug.p

Re: [PHP-DEV] [PATCH] fix imap_mail actually use the rpath option

2011-08-04 Thread Keloran
patch attached On Thu, Aug 4, 2011 at 4:39 PM, Pierre Joye wrote: > hi, > > Can you attach this patch to the bug please? > > Thanks for your work! > > On Thu, Aug 4, 2011 at 5:30 PM, Keloran wrote: > > Index: ext/imap/php_imap.c > > ==

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Brian Moon
From your blog post: > All in all, I have tried to eliminate the syntax noise by > reducing the key strokes in the the non-significant parts > of the expression is typing time really the bottleneck for > productivity Is typing really the bottleneck for developers these days? I must suck then. I

Re: [PHP-DEV] [PATCH] fix imap_mail actually use the rpath option

2011-08-04 Thread Pierre Joye
hi, Can you attach this patch to the bug please? Thanks for your work! On Thu, Aug 4, 2011 at 5:30 PM, Keloran wrote: > Index: ext/imap/php_imap.c > === > --- ext/imap/php_imap.c (revision 314217) > +++ ext/imap/php_imap.c (working

[PHP-DEV] [PATCH] fix imap_mail actually use the rpath option

2011-08-04 Thread Keloran
Index: ext/imap/php_imap.c === --- ext/imap/php_imap.c (revision 314217) +++ ext/imap/php_imap.c (working copy) @@ -4016,7 +4016,27 @@ if (!INI_STR("sendmail_path")) { return 0; } - sendmail = pope

Re: [PHP-DEV] 5.3.7 is there a RC5 coming soon?

2011-08-04 Thread Ilia Alshanetsky
Unless something changes, I think we are going to go from RC4 to final release. On Wed, Aug 3, 2011 at 8:29 PM, James Yu wrote: > Thanks! > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > > -- PHP Internals - PHP Runtime Develo

Re: [PHP-DEV] Memory management ...

2011-08-04 Thread Johannes Schlüter
On Thu, 2011-08-04 at 12:36 +0100, Lester Caine wrote: > Ferenc Kovacs wrote: > > so to address your question: if you unset your variables you can > > reclaim memory, but there could be edge cases, when you will memory > > leak before version 5.3. > > So it looks like I'm not hitting any edge case

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Antony Dovgal
On 08/04/2011 05:04 PM, Derick Rethans wrote: On Thu, 4 Aug 2011, Victor Bolshov wrote: Btw, am I the only one to whom the proposed syntax seems kinda hieroglyphic? No. I don't see at all why we need this, just like I don't see why we needed an alternative (short) syntax for arrays. This kin

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Derick Rethans
On Thu, 4 Aug 2011, Victor Bolshov wrote: > Btw, am I the only one to whom the proposed syntax seems kinda hieroglyphic? No. I don't see at all why we need this, just like I don't see why we needed an alternative (short) syntax for arrays. This kind of syntax additions that add *no* functionali

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Victor Bolshov
+1 - think everybody'd want their functions to be searchable and searching for complex patterns like "(function)|(\|\=\>)" would really be a headache. Btw, am I the only one to whom the proposed syntax seems kinda hieroglyphic? 2011/8/4 Antony Dovgal > On 08/04/2011 04:39 PM, Lazare Inepologlou

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Antony Dovgal
On 08/04/2011 04:39 PM, Lazare Inepologlou wrote: ... ( $x ) => $x + 1 for example would be ambiguous if used in an array definition, but is otherwise the best in terms of readability. ... people wanted an easy way to grep for function declarations A new and unique operator (like the |=

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Lazare Inepologlou
> ... ( $x ) => $x + 1 for example would be ambiguous if used in an array > definition, but is otherwise the best in terms of readability. > ... people wanted an easy way to grep for function declarations A new and unique operator (like the |=> I have proposed) is a solution that works because:

Re: [PHP-DEV] [VOTE] Weak References

2011-08-04 Thread Lars Schultz
Am 04.08.2011 09:17, schrieb Stas Malyshev: I'm sorry but you putting forth contradictory requirements here - you want to keep the objects (to avoid "expensively reconstructing" them) and you don't want to keep them (memory problems). You'll have to give up one of these requirements. As I see, yo

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Arvids Godjuks
Oh, and I forgot one more thing: As I read the internals, I noticed many times that PHP lexer is somewhat limited in it's capabilities and sometimes the features are dropped because of this issue. It can be the case that the can be ambiguous and it will be just impossible to add at this stage. As

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Arvids Godjuks
2011/8/4 Lazare Inepologlou : > Hello everyone. > > I am new to the php-internals list. I have joined because I have > implemented a feature that I would like to be included in the php > language: a shorter syntax for lambdas. I am going to briefly present > it here. Apologies for the long (and yet

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Johannes Schlüter
On Thu, 2011-08-04 at 21:18 +1000, Ryan McCue wrote: > Lazare Inepologlou wrote: > > Thank you for your interest. This is just a proposal that I have tested and > > works. Of course, the final syntax can be different. Syntax is always a > > matter of taste :-) > > As much as I love the idea, I hav

Re: [PHP-DEV] Memory management ...

2011-08-04 Thread Lester Caine
Ferenc Kovacs wrote: so to address your question: if you unset your variables you can reclaim memory, but there could be edge cases, when you will memory leak before version 5.3. So it looks like I'm not hitting any edge cases in the earlier code as some sites have been running for years witho

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Ryan McCue
Lazare Inepologlou wrote: > Thank you for your interest. This is just a proposal that I have tested and > works. Of course, the final syntax can be different. Syntax is always a > matter of taste :-) As much as I love the idea, I have to agree that using | doesn't really make sense here and actual

Re: [PHP-DEV] 5.3.7 is there a RC5 coming soon?

2011-08-04 Thread Johannes Schlüter
On Wed, 2011-08-03 at 17:29 -0700, James Yu wrote: > Thanks! Why do you need a 5th RC? Anything of importance changed? You want to get a patch in? Ilia, who thankfully took over this release, wrote in a mail about RC4: Given the small number of changes since the last RC, it is lik

Re: [PHP-DEV] Memory management ...

2011-08-04 Thread Ferenc Kovacs
On Thu, Aug 4, 2011 at 12:17 PM, Lester Caine wrote: > I'm still trying to get my head around this 'Weak Reference' thing, but > since I'm still working to be compatible with PHP5.2 then I've not taken > much notice of this 'garbage collection' stuff. So this may be where I am > missing something?

[PHP-DEV] Memory management ...

2011-08-04 Thread Lester Caine
I'm still trying to get my head around this 'Weak Reference' thing, but since I'm still working to be compatible with PHP5.2 then I've not taken much notice of this 'garbage collection' stuff. So this may be where I am missing something? I manage what material I need using a list of numbers, and

Re: [PHP-DEV] [VOTE] Weak References

2011-08-04 Thread Ferenc Kovacs
On Thu, Aug 4, 2011 at 10:37 AM, Lester Caine wrote: > Stas Malyshev wrote: >>> >>> I am open to any suggestions how I could solve my problem without >>> WeakReference or zval-refcount (short of keeping a ref-count in >>> userland). >> >> Do not keep object references, keep object IDs. This would

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Ivan Enderlin @ Hoa
Hi all :-), On 04/08/11 09:23, Rasmus Lerdorf wrote: On 08/04/2011 12:08 AM, Lazare Inepologlou wrote: $add = | $x |=> | $y : $x |=> $x+$y; This does not seem to match the syntax of any language I know of so people are going to have a hard time figuring out what this does. It's not even clea

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Lazare Inepologlou
Hello, >> $add = | $x |=> | $y : $x |=> $x+$y; > Not sure that it's really readable. This is not the most trivial example. In my blog, there is a small sub-section where I explain why this is more readable than an implementation with the current syntax. See under "Readability" and "A more complic

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Lazare Inepologlou
Good morning Rasmus, Thank you for your interest. This is just a proposal that I have tested and works. Of course, the final syntax can be different. Syntax is always a matter of taste :-) > it is only useful in one limited type of trivial closure usage This trivial usage is actually the most c

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Frédéric Hardy
Hello ! I've always thought that just supressing the "function" keyword could work as a shorthand, i.e. having ([param1 [, param2 [, ...]]]){...}. Somewhat similar to Ruby's lambda shorthand: http://slideshow.rubyforge.org/ruby19.html#40 Huge +1 for that. Code using closures will be more read

[PHP-DEV] test

2011-08-04 Thread Frédéric Hardy
Hello ! It's a test. Sorry for noise. Best regards, Fred -- Frédéric Hardy : Architecte d'application/Admin. système/Ergonome CV : http://blog.mageekbox.net/public/cv.frederic.hardy.pdf Blog : http://bl

Re: [PHP-DEV] [VOTE] Weak References

2011-08-04 Thread Lester Caine
Stas Malyshev wrote: I am open to any suggestions how I could solve my problem without WeakReference or zval-refcount (short of keeping a ref-count in userland). Do not keep object references, keep object IDs. This would make your code a bit more verbose and a bit slower, but weak refs would es

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Stas Malyshev
Hi! On 8/4/11 12:31 AM, dukeofgaming wrote: I've always thought that just supressing the "function" keyword could work as a shorthand, i.e. having ([param1 [, param2 [, ...]]]){...}. Somewhat similar to Ruby's lambda shorthand: http://slideshow.rubyforge.org/ruby19.html#40 My opinion is that w

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread dukeofgaming
Hi, I've always thought that just supressing the "function" keyword could work as a shorthand, i.e. having ([param1 [, param2 [, ...]]]){...}. Somewhat similar to Ruby's lambda shorthand: http://slideshow.rubyforge.org/ruby19.html#40 Regards, David On Thu, Aug 4, 2011 at 2:23 AM, Rasmus Lerdorf

Re: [PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Rasmus Lerdorf
On 08/04/2011 12:08 AM, Lazare Inepologlou wrote: > $add = | $x |=> | $y : $x |=> $x+$y; This does not seem to match the syntax of any language I know of so people are going to have a hard time figuring out what this does. It's not even clear that |=> is a new operator there due to the dangling |,

Re: [PHP-DEV] [VOTE] Weak References

2011-08-04 Thread Stas Malyshev
Hi! On 8/3/11 11:03 PM, Lars Schultz wrote: (from the cache). This works very well and keeps me from expensively reconstructing objects from the DB. What it does not work well with is Garbage collection, since the an object will always be referenced at least once (by the cache). The longer a scr

[PHP-DEV] An implementation of a short syntax for closures

2011-08-04 Thread Lazare Inepologlou
Hello everyone. I am new to the php-internals list. I have joined because I have implemented a feature that I would like to be included in the php language: a shorter syntax for lambdas. I am going to briefly present it here. Apologies for the long (and yet incomplete) e-mail. I am ready to write