Re: [PHP-DEV] New syntax for multidimensional array loop with foreach

2013-06-27 Thread Yahav Gindi Bar
On Thu, Jun 27, 2013 at 5:27 PM, Ralf Lang wrote: > On 27.06.2013 16:10, Christian Stoller wrote: > > Hi internals, > > > > during my current work I had an idea for shorter array iteration with > foreach. I haven’t seen such a syntax until now, but I think it is easy to > understand ;-) > > > > M

Re: [PHP-DEV] RFC: Protocol Type Hinting

2013-06-25 Thread Yahav Gindi Bar
On Wed, Jun 26, 2013 at 1:16 AM, Stas Malyshev wrote: > Hi! > > > This may sound trivial, but imagine this. Right now Zend and Symfony have > > very similar providers for certain tasks. One of the ones that comes to > > mind (besides logging) is caching. If you want to use a Zend component in > >

Re: [PHP-DEV] RFC: Protocol Type Hinting

2013-06-25 Thread Yahav Gindi Bar
On 6/25/13 10:57 AM, Anthony Ferrara wrote: > >> Hey all, >> >> I want to throw out this draft RFC to get the concept floating around and >> get feedback early. >> >> https://wiki.php.net/rfc/**protocol_type_hinting >> >> There are still open question

Re: [PHP-DEV] RE: Announcing RFC 'Anonymous Catches'

2013-06-25 Thread Yahav Gindi Bar
I, too, believes that omitting the exception variable is great. In addition, anonymous catch blocks will shorten the code of "catch (Exception $e)" so... is just a simpler way of writing - and that's what PHP agenda aiming for, doesn't it? be a friendly and readable language. Reading try { $fo

Re: [PHP-DEV] [RFC] Short syntax for anonymous functions

2013-02-19 Thread Yahav Gindi Bar
On Tue, Feb 19, 2013 at 6:40 PM, Levi Morrison wrote: > > Say we agree on the syntax above > >> ($n) |$m| => $m * $n; > > What happens when my one liner function needs to do one more operation > > like checking the value of $n before multiplication? > > As I stated before suggesting the syntax: It

Re: [PHP-DEV] A remark about PHP's Vision and new things.

2013-01-12 Thread Yahav Gindi Bar
On Sat, Jan 12, 2013 at 7:35 AM, Levi Morrison wrote: > > Can we re-write PHP with PHP? ;) > > Anthony and Nikita are already on it: https://github.com/ircmaxell/PHPPHP > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > > Just wish

Re: [PHP-DEV] Re: Was Reflection annotations reader - We Need A Vision

2013-01-10 Thread Yahav Gindi Bar
Agree, I thought about Those who don't want to annotations at all. So we can add 2 extra options for those who don't want annotations at all and those who wish better proposal :) PS : I'm with those who do wish annotations. ב-11 בינו 2013, בשעה 01:07, Ralf Lang כתב/ה: > -BEGIN PGP SIGNED

Re: [PHP-DEV] Re: Was Reflection annotations reader - We Need A Vision

2013-01-10 Thread Yahav Gindi Bar
On Thu, Jan 10, 2013 at 10:42 PM, Anthony Ferrara wrote: > Stas, > > > On Thu, Jan 10, 2013 at 3:16 PM, Stas Malyshev >wrote: > > > Hi! > > > > > Sure. Here you go. Here are two examples: > > > > > > http://www.python.org/dev/peps/pep-0020/ > > > > This is a nice text, but practical meaning of it

Re: [PHP-DEV] Was Reflection annotations reader - We Need A Vision

2013-01-09 Thread Yahav Gindi Bar
On Thu, Jan 10, 2013 at 4:05 AM, Tyler Sommer wrote: > Annotations are already a part of PHP. They are widely used in one of the > most prolific frameworks, Symfony, and it's ORM "counterpart" Doctrine. > Both of which are serious drivers of the PHP community. It's > even potentially spreading to

Re: [PHP-DEV] - True Annotations

2013-01-09 Thread Yahav Gindi Bar
On Wed, Jan 9, 2013 at 2:09 PM, Christian Kaps wrote: > Am 09.01.2013 13:03, schrieb Yahav Gindi Bar: > >> On Wed, Jan 9, 2013 at 1:57 PM, Christian Kaps > >**wrote: >> >> Hi, >>> >>> >>> I agree here, I think the above, if possib

Re: [PHP-DEV] - True Annotations

2013-01-09 Thread Yahav Gindi Bar
On Wed, Jan 9, 2013 at 1:57 PM, Christian Kaps wrote: > Hi, > > > I agree here, I think the above, if possible would be best. In my >> mind annotations should proabably be limited in scope to class >> declarations and thus only before a class keyword, before a property >> or method declaration.

Re: [PHP-DEV] [RFC] Reflection annotations reader

2013-01-09 Thread Yahav Gindi Bar
On Wed, Jan 9, 2013 at 10:29 AM, Leigh wrote: > In my opinion (for however little it matters), code is code, and comments > are comments. They should not mingle. > > Annotations, if implemented, should have their own syntax that makes them > code, not an abstraction of a comment. > > I already di

Re: [PHP-DEV] [RFC] Reflection annotations reader

2013-01-08 Thread Yahav Gindi Bar
> If I read this thread correctly then almost everyone agrees that PHPUnit, > Symfony, ZF, Doctrine, etc, all use annotations in the DocBlock because > there > is no available alternative that enables them to use annotations. > Yes, I understood that too. As far as I am concerned I'd separate th

Re: [PHP-DEV] [RFC] Reflection annotations reader

2013-01-08 Thread Yahav Gindi Bar
Hi, Firstly - many apologizes for not follwoing along, couldn't be near my mail yesterday (university...). Many apologizes for the long response too ;). > . > There is already a similar RFC here :) Maybe it could be good to start > from this one so that we don't have any duplicated RFC ? > > http

Re: [PHP-DEV] [RFC] Reflection annotations reader

2013-01-06 Thread Yahav Gindi Bar
public function foo(DateTime $date) { ... } > } > > -Clint > > On Jan 6, 2013, at 3:58 PM, Yahav Gindi Bar wrote: > > > Hi internals! > > > > In one of the discussions (about the "deprecated" keyword, to be > specific), > > it was been said that adding abil

Re: [PHP-DEV] [RFC] Reflection annotations reader

2013-01-06 Thread Yahav Gindi Bar
On Mon, Jan 7, 2013 at 1:11 AM, Sebastian Krebs wrote: > 2013/1/6 Yahav Gindi Bar > > > On Mon, Jan 7, 2013 at 12:41 AM, Marco Pivetta > wrote: > > > > > > > > I think that our work is to isolate each annotation so it'll be easy to > > >&

Re: [PHP-DEV] [RFC] Reflection annotations reader

2013-01-06 Thread Yahav Gindi Bar
On Mon, Jan 7, 2013 at 12:41 AM, Marco Pivetta wrote: > > I think that our work is to isolate each annotation so it'll be easy to >> access, then, it'll be easy enough to write the code that creates "complex >> annotations", such as constructors and so on, in userland. >> > > In fact, there's pro

Re: [PHP-DEV] [RFC] Reflection annotations reader

2013-01-06 Thread Yahav Gindi Bar
On Mon, Jan 7, 2013 at 12:24 AM, Lars Strojny wrote: > Hi Yahav, > > Am 06.01.2013 um 22:58 schrieb Yahav Gindi Bar : > [...] > > In one of the discussions (about the "deprecated" keyword, to be > specific), > > it was been said that adding ability to rea

[PHP-DEV] [RFC] Reflection annotations reader

2013-01-06 Thread Yahav Gindi Bar
Hi internals! In one of the discussions (about the "deprecated" keyword, to be specific), it was been said that adding ability to read doc-comment annotation could be handy. Personally, I really think it can be great. So, I've created an RFC that propose to improve the Reflection extension by add

Re: [PHP-DEV] RFC: Add a deprecated modifier for functions

2012-12-26 Thread Yahav Gindi Bar
On Wed, Dec 26, 2012 at 5:48 PM, Yussuf Khalil wrote: > Hello, > > assuming that you are referring to the RFC about annotations ( > https://wiki.php.net/rfc/**annotations) > I don't think that annotations are needed in PHP. Declarations that > actually have a

Re: [PHP-DEV] RFC: Add a deprecated modifier for functions

2012-12-26 Thread Yahav Gindi Bar
On Wed, Dec 26, 2012 at 4:22 PM, Yussuf Khalil wrote: > Hello, > > I have created an RFC about adding a deprecated modifier for functions in > PHP, see > https://wiki.php.net/rfc/**deprecated-modifier. > What are your thoughts on this? > > Thank you,

Re: [PHP-DEV] Alternatives to mailing list?

2012-10-16 Thread Yahav Gindi Bar
prefer to get > everything via email, I believe it is possible to sync VBulletin with a > mailing list. > > > > On 10/16/2012 5:18 PM, Yahav Gindi Bar wrote: > >> I may sound old fashioned, but what about a forum? >> >> On Wed, Oct 17, 2012 at 3:05 AM, Clint

Re: [PHP-DEV] Alternatives to mailing list?

2012-10-16 Thread Yahav Gindi Bar
I may sound old fashioned, but what about a forum? On Wed, Oct 17, 2012 at 3:05 AM, Clint Priest wrote: > Is it just me or has this Property Accessors chain of emails been > impossible to make heads or tails of? People replying within replies > within replies, quoting partial emails, cross-post

Re: [PHP-DEV] Authenticated Encryption in PHP

2012-09-20 Thread Yahav Gindi Bar
To be honest, I've thought about it today and think that it could be great! :) I'd love to help if it's possible in any way I can :) On Thu, Sep 20, 2012 at 5:48 PM, Chad Emrys wrote: > Hello, > > I was wondering how difficult it would be to add access to a standard > authenticated encryption mo

Re: [PHP-DEV] Why are the PHP namespaces different compared to C++?

2012-09-06 Thread Yahav Gindi Bar
On Fri, Sep 7, 2012 at 3:41 AM, Stas Malyshev wrote: > Hi! > > > How about adding ability to import the entire namespace? > > This option was explicitly excluded because this defeats the whole idea > of having namespaces - i.e. having names to live in different spaces - > by explicitly bringing un

Re: [PHP-DEV] Why are the PHP namespaces different compared to C++?

2012-09-06 Thread Yahav Gindi Bar
On Fri, Sep 7, 2012 at 3:21 AM, Levi Morrison wrote: > On Thu, Sep 6, 2012 at 6:15 PM, Sherif Ramadan > wrote: > > On Thu, Sep 6, 2012 at 5:30 PM, Mark wrote: > >> Hi, > >> > >> I was just using the PHP namespaces for the first time and noticed a > >> difference that i really didn't expect. (No,

Re: [PHP-DEV] Re: [VOTE]Call for voting: support use list in foreach

2012-08-26 Thread Yahav Gindi Bar
On Sun, Aug 26, 2012 at 10:20 PM, Lester Caine wrote: > Yahav Gindi Bar wrote: > >> OK, I stand corrected then, but participation rate is still awfully low. >>>> > >We can't talk about consensus when everything is decided on one vote. >>>> >>&

Re: [PHP-DEV] Re: [VOTE]Call for voting: support use list in foreach

2012-08-26 Thread Yahav Gindi Bar
On Sun, Aug 26, 2012 at 9:44 PM, Ferenc Kovacs wrote: > > > On Sun, Aug 26, 2012 at 8:20 PM, Stas Malyshev wrote: > >> Hi! >> >> > And this is how democracy works, Stas. If voters don't bother to turn >> > up, too bad. >> >> Putting aside the fact that democracy has very little to do with what >>

Re: [PHP-DEV] Re: [VOTE]Call for voting: support use list in foreach

2012-08-26 Thread Yahav Gindi Bar
nd really make sense~ > And this is how democracy works, Stas. If voters don't bother to turn up, > too bad. > > Yes, but even in democracy there's a minimum votes rate... I don't think that core decision should be done using 15 votes... > > -- > Sent from Samsun

Re: [PHP-DEV] Re: [VOTE]Call for voting: support use list in foreach

2012-08-26 Thread Yahav Gindi Bar
On Sun, Aug 26, 2012 at 9:00 PM, Will Fitch wrote: > Maybe the simplest solution is we have a minimum participation rate before > voting can be closed? > > Though it make sense - it's a problem, because it'll delay and reject some useful features because of requirements issue. > On Sun, Aug 26,

Re: [PHP-DEV] Re: [VOTE]Call for voting: support use list in foreach

2012-08-26 Thread Yahav Gindi Bar
On Sun, Aug 26, 2012 at 8:42 PM, Stas Malyshev wrote: > Hi! > > >foreach supports list syntax: 11 for yes, 4 for no. accepted. > >foreach supports list with silent token: 2 for yes, 10 for no. > denied. > > And here's again the problem with this voting setup. With all these long > di

Re: [PHP-DEV] Aspect Oriented Programming in PHP

2012-08-23 Thread Yahav Gindi Bar
On Thu, Aug 23, 2012 at 11:11 PM, Ralph Schindler wrote: > I've started using this extension on a personal project. So far, I really > love it. If the performance aspects of it remain minimal, and the syntax > remains simple/non-complex, I can see this as a component that would > benefit many by

Re: [PHP-DEV] [RFC] Generators

2012-08-20 Thread Yahav Gindi Bar
On Mon, Aug 20, 2012 at 3:48 PM, Rasmus Lerdorf wrote: > On 08/20/2012 07:56 AM, Ángel González wrote: > > On 20/08/12 02:01, Rasmus Lerdorf wrote: > >> I would still like to understand what this generator keyword would > >> actually do. I don't see how it would work. Would a function marked > >>

Re: [PHP-DEV] Proposal: use SomeClass::staticMethod

2012-08-15 Thread Yahav Gindi Bar
On Wed, Aug 15, 2012 at 2:09 PM, Paul Dragoonis wrote: > Comments inline. > > On Wed, Aug 15, 2012 at 11:59 AM, Giedrius Dubinskas > wrote: > > Hello Internals! > > > > I'm just on and off luker here but thought I'll throw in an idea for a > > feature I'd love to see in PHP: aliasing static meth

Re: [PHP-DEV] RFC page creation

2012-08-14 Thread Yahav Gindi Bar
On Tue, Aug 14, 2012 at 10:54 PM, Ferenc Kovacs wrote: > > > On Tue, Aug 14, 2012 at 9:19 PM, Kris Craig wrote: > >> > >> > Put that aside, I think that someone should create a guidelines in the >> > wiki about how to post an RFC without an account... >> > >> >> Ironically, I think we'd need to

Re: [PHP-DEV] RFC page creation

2012-08-14 Thread Yahav Gindi Bar
On Tue, Aug 14, 2012 at 9:47 PM, Kris Craig wrote: > > > On Tue, Aug 14, 2012 at 10:28 AM, Yahav Gindi Bar wrote: > >> Hi, >> >> I believe its a newbie question, but because I only replied to mails and >> didn't create any RFC page yet I wish to confirm.

[PHP-DEV] RFC page creation

2012-08-14 Thread Yahav Gindi Bar
Hi, I believe its a newbie question, but because I only replied to mails and didn't create any RFC page yet I wish to confirm. I wish to create an RFC page for a feature discussion, but I can't do it from the wiki page (think it's lack of permissions issue). I've looked at the mailing list logs a

Re: [PHP-DEV] [RFC] Generators

2012-08-12 Thread Yahav Gindi Bar
On 13 באוג 2012, at 01:33, Levi Morrison wrote: > On Sun, Aug 12, 2012 at 2:08 PM, Brian Moon wrote: >> Do you have a good example usage other than a file? I don't find >> fopen/fgets/fclose all that complicated. What are the other valid use cases >> for such a thing? > > One fabulous use ca

Re: [PHP-DEV] Integrate PECL into PHP

2012-08-04 Thread Yahav Gindi Bar
On Sat, Aug 4, 2012 at 11:12 PM, Ferenc Kovacs wrote: > > > On Sat, Aug 4, 2012 at 9:57 PM, Yahav Gindi Bar wrote: > >> Hi, >> >> After the last discussion I've started about runkit which some of you >> suggest to keep it in PECL - I thought about the e

Re: [PHP-DEV] Integrate PECL into PHP

2012-08-04 Thread Yahav Gindi Bar
On Sat, Aug 4, 2012 at 11:03 PM, Nikita Popov wrote: > On Sat, Aug 4, 2012 at 9:57 PM, Yahav Gindi Bar > wrote: > > We had dl() until it was deprecated, and even when we got it I guess that > > administrators disabled the dl() method because of security reasons. > > H

[PHP-DEV] Integrate PECL into PHP

2012-08-04 Thread Yahav Gindi Bar
Hi, After the last discussion I've started about runkit which some of you suggest to keep it in PECL - I thought about the extensions "problem" in PHP and wish to ask for your opinion. Many developers use shared hosting as PHP env which not allows them to install new extensions in PHP. In order t

Re: [PHP-DEV] Add runkit to PHP Runtime

2012-08-03 Thread Yahav Gindi Bar
On Fri, Aug 3, 2012 at 10:23 AM, Lester Caine wrote: > Yahav Gindi Bar wrote: > >> Maybe I'm wrong when comparing with other languages and mainly with >> ASP.NET(C#) since they've used it for web proposes but I did saw many >> >> classes that used th

Re: [PHP-DEV] Add runkit to PHP Runtime

2012-08-02 Thread Yahav Gindi Bar
On Fri, Aug 3, 2012 at 5:46 AM, Sherif Ramadan wrote: > > > > I don't see why this is not a good programming practice, lets get the > > following example: > > class Member { > > public static function create(...) { } > > public function update(...) { } > > public function remove(...) {

Re: [PHP-DEV] Add runkit to PHP Runtime

2012-08-02 Thread Yahav Gindi Bar
On Fri, Aug 3, 2012 at 3:07 AM, Anthony Ferrara wrote: > Yahav, > > > On Thu, Aug 2, 2012 at 7:26 PM, Yahav Gindi Bar wrote: > >> I do think that some of the runkit features should not be included in PHP >> core but I wish to focus on extending classes with exte

Re: [PHP-DEV] Add runkit to PHP Runtime

2012-08-02 Thread Yahav Gindi Bar
I do think that some of the runkit features should not be included in PHP core but I wish to focus on extending classes with extension methods, constants, traits and members. Just like all other complicated and powerful features in PHP, one should use them with a good reason and when he/she knows

Re: [PHP-DEV] Add runkit to PHP Runtime

2012-08-02 Thread Yahav Gindi Bar
On Thu, Aug 2, 2012 at 7:56 PM, Leigh wrote: > > On Aug 2, 2012 5:44 PM, "Yahav Gindi Bar" wrote: > > > > Hi, > > > > I don't know how to tag this kind of discussion (because it's not RFC > > request). > > I've interested in ru

[PHP-DEV] Add runkit to PHP Runtime

2012-08-02 Thread Yahav Gindi Bar
Hi, I don't know how to tag this kind of discussion (because it's not RFC request). I've interested in runkit PECL extension and think that it should be part of the PHP core runtime. I do think that the implementation should be different and don't mind to suggest my implementation as RFC, but fir

Re: [PHP-DEV] Generators in PHP

2012-07-25 Thread Yahav Gindi Bar
On 26 ביול 2012, at 01:22, Alex Aulbach wrote: > 2012/7/25 Nikita Popov : >> particular with namespaced code). So if you have some kind of >> Code\Generator class, you're screwed. >> Keywords don't grow on trees, you know ;) > > Hm. Ok, thats a problem. > Oh, man, do I really have to find a goo

Re: [PHP-DEV] Re: Generators in PHP

2012-07-24 Thread Yahav Gindi Bar
. On 24 ביול 2012, at 20:56, Alex Aulbach wrote: > 2012/7/24 Andrew Faulds : >> Much easier to make an iterator with a function than as a class. > > 2012/7/24 Yahav Gindi Bar : >> I agree, implementing a class only for iterator may be pain sometimes, and >> fu

Re: [PHP-DEV] Implicit isset in ternary operator

2012-07-24 Thread Yahav Gindi Bar
On 24 ביול 2012, at 20:15, Alex Aulbach wrote: > 2012/7/24 Yahav Gindi Bar : >> I don't think global operators is good idea since it can make a script very >> complex and you'll have to learn many operators in case the one who wrote it >> decided to make it &quo

Re: [PHP-DEV] Re: Generators in PHP

2012-07-24 Thread Yahav Gindi Bar
On 24 ביול 2012, at 20:35, Andrew Faulds wrote: > On 24/07/12 18:34, Alex Aulbach wrote: >> 2012/7/23 Sara Golemon : >>> Curious if you could expand on that. Generators are iterators, so not sure >>> what you're asking for. >> It's the point which is unlogical for me. Maybe it's a question. If >>

Re: [PHP-DEV] Implicit isset in ternary operator

2012-07-24 Thread Yahav Gindi Bar
On 24 ביול 2012, at 19:18, Alex Aulbach wrote: > 2012/7/24 Galen Wright-Watson : >>> Don't see much difference between >>> >>> $a = $b ?: $c; >>> >>> and (for example I used "i" for "if") >>> >>> $a = _i($b, $c); >> >> >> When $b is defined, there isn't much appreciable difference. However,

Re: [PHP-DEV] array_pick() - resent because email client broke formatting

2012-07-23 Thread Yahav Gindi Bar
On 23 ביול 2012, at 19:05, Anthony Ferrara wrote: > Andrew, > > On Mon, Jul 23, 2012 at 9:26 AM, Andrew Faulds wrote: > >> >> (resending because of broken formatting) >> >> Hi there, >> >> I apologise for my previous email. It was a disorganised mess that didn't >> really >> make the case f

Re: [PHP-DEV] Implicit isset in ternary operator

2012-07-22 Thread Yahav Gindi Bar
On Mon, Jul 23, 2012 at 6:12 AM, Alex Aulbach wrote: > Do we really need that as operator? Why not using new functions for > special cases. > Don't see much difference between > > $a = $b ?: $c; > > and (for example I used "i" for "if") > > $a = _i($b, $c); > > Just a manner of getting accustomed