Re: [PHP-DEV] Proposing [constructive] solutions (was: I quit)

2015-02-16 Thread Lester Caine
On 16/02/15 15:31, François Laupretre wrote: - There is a lack of expertise at the core level of the code, so collaboration on each feature is low. RFCs tend to have a single sponsor, who has to see the whole process through to the end. - One thing we can encourage, while indirect in this

Re: [PHP-DEV] PHP JIT or AOT

2015-02-16 Thread Dmitry Stogov
On Mon, Feb 16, 2015 at 5:21 PM, Anthony Ferrara ircmax...@gmail.com wrote: Dmitry, On Mon, Feb 16, 2015 at 9:12 AM, Dmitry Stogov dmi...@zend.com wrote: The type checks in PHP7 is quite cheap (2-3 CPU instructions). Strict or weak check doesn't make any difference for fast path (the

Re: [PHP-DEV] Re: Annotations in PHP7

2015-02-16 Thread Rowan Collins
On Mon, Feb 16, 2015 at 6:41 PM, Rowan Collins rowan.coll...@gmail.com mailto:rowan.coll...@gmail.com wrote: Is there any value in deciding the initial syntax for 7.0, and implementing only non-parameterised annotations, i.e. you can call hasAnnotation(string): bool but nothing else?

Re: [PHP-DEV] Proposing [constructive] solutions (was: I quit)

2015-02-16 Thread Johannes Schlüter
On Mon, 2015-02-16 at 16:31 +0100, François Laupretre wrote: De : Rowan Collins [mailto:rowan.coll...@gmail.com] Saying that's enough isn't even a productive comment. Enough what? What is it you are asking to happen next? Maybe an initiative to write an RFC about the rules we should

[PHP-DEV] Reviving scalar type hints

2015-02-16 Thread François Laupretre
Hi, De : Arvids Godjuks [mailto:arvids.godj...@gmail.com] The 0.1 RFC version was mentioned a lot as a good compromise by many people and had major support. Maybe someone competent could pick it up, make necessary adjustments that where required and let people vote on it? Start with

Re: [PHP-DEV] Re: I quit.

2015-02-16 Thread Arvids Godjuks
2015-02-16 17:26 GMT+02:00 Daniel Lowrey rdlow...@php.net: On Mon, Feb 16, 2015 at 10:19 AM, Zeev Suraski z...@zend.com wrote: -Original Message- From: rdlow...@gmail.com [mailto:rdlow...@gmail.com] On Behalf Of Daniel Lowrey Sent: Monday, February 16, 2015 5:13 PM To:

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Peter Cowburn
On 16 February 2015 at 16:42, François Laupretre franc...@php.net wrote: Hi, De : Arvids Godjuks [mailto:arvids.godj...@gmail.com] The 0.1 RFC version was mentioned a lot as a good compromise by many people and had major support. Maybe someone competent could pick it up, make

Re: [PHP-DEV] Re: Annotations in PHP7

2015-02-16 Thread Dmitry Stogov
this will work, of course, and robust implementation wouldn't take more than a day :) but it'll require user-level parser again. no big advantage in comparison to doc-block. Thanks. Dmitry. On Mon, Feb 16, 2015 at 6:41 PM, Rowan Collins rowan.coll...@gmail.com wrote: Nikita Popov wrote on

[PHP-DEV] Re: Reviving scalar type hints

2015-02-16 Thread Arvids Godjuks
2015-02-16 18:42 GMT+02:00 François Laupretre franc...@php.net: Hi, De : Arvids Godjuks [mailto:arvids.godj...@gmail.com] The 0.1 RFC version was mentioned a lot as a good compromise by many people and had major support. Maybe someone competent could pick it up, make necessary

Re: [PHP-DEV] Re: I quit.

2015-02-16 Thread Daniel Lowrey
On Mon, Feb 16, 2015 at 11:00 AM, Arvids Godjuks arvids.godj...@gmail.com wrote: This bickering already jeopardized the type hinting RFC's how many times? 3 as I recall? Zeev was kind enough to reach out privately prior to your message and we began exchanged mails trying to better understand

[PHP-DEV] Re: Annotations in PHP7

2015-02-16 Thread Stanislav Malyshev
Hi! The test there is self explainable. Of course, annotations just provide a way to add metadata, but doesn't define attribute names or the ways they are going to be used. Only Reflection API to read. Looks fine, but I'm not sure how one can use the AST that the reflection returns. Is it for

[PHP-DEV] [RFC] [VOTE] Remove the date.timezone warning

2015-02-16 Thread Bob Weinand
As announced yesterday, I put the RFC into vote now. Voting period is 8 days, it will end 24th of February. The RFC is here: https://wiki.php.net/rfc/date.timezone_warning_removal https://wiki.php.net/rfc/date.timezone_warning_removal I also slightly reworded the feedback section in reply to

[PHP-DEV] Done something wrong ...

2015-02-16 Thread Lester Caine
I've synced with current git and seem to have the files I expect for interbase, but when trying to run a clean build of the core stuff it no longer compiles ... For example /srv/repo/php-src_master/ext/opcache/ZendAccelerator.c:2005:19: error: ‘zend_array’ has no member named ‘pDestructor’ Seems

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Dmitry Stogov
On Mon, Feb 16, 2015 at 7:42 PM, François Laupretre franc...@php.net wrote: Hi, De : Arvids Godjuks [mailto:arvids.godj...@gmail.com] The 0.1 RFC version was mentioned a lot as a good compromise by many people and had major support. Maybe someone competent could pick it up, make

Re: [PHP-DEV] Done something wrong ...

2015-02-16 Thread Martin Jansen
On 16.02.15 20:46, Lester Caine wrote: On 16/02/15 18:34, Ferenc Kovacs wrote: On Mon, Feb 16, 2015 at 6:55 PM, Lester Caine les...@lsces.co.uk wrote: /srv/repo/php-src_master/ext/opcache/ZendAccelerator.c:2005:19: error: ‘zend_array’ has no member named ‘pDestructor’ Seems to be due to

[PHP-DEV] Re: Annotations in PHP7

2015-02-16 Thread Dmitry Stogov
On Mon, Feb 16, 2015 at 8:41 PM, Stanislav Malyshev smalys...@gmail.com wrote: Hi! The test there is self explainable. Of course, annotations just provide a way to add metadata, but doesn't define attribute names or the ways they are going to be used. Only Reflection API to read. Looks

RE: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread François Laupretre
Hi, De : morrison.l...@gmail.com [mailto:morrison.l...@gmail.com] De la part Also, I know people REALLY want scalar types in PHP 7.0 but honestly all we need to do is reserve the keywords so there is no BC impact and then we can do it at any point during the PHP 7 lifecycle. This is my

Re: [PHP-DEV] filter_var doesn't support international email addresses

2015-02-16 Thread j adams
Rowan, thanks for your response. Wow that regex is pretty intense. A new filter type sounds like a reasonable idea to me. I'm not sure if I'll be able to offer any improvements myself (although I will look into it shortly here). I I do know that Google announced last August that they plan to

Re: [PHP-DEV] Done something wrong ...

2015-02-16 Thread Ferenc Kovacs
On Mon, Feb 16, 2015 at 6:55 PM, Lester Caine les...@lsces.co.uk wrote: I've synced with current git and seem to have the files I expect for interbase, but when trying to run a clean build of the core stuff it no longer compiles ... For example

Re: [PHP-DEV] Re: I quit.

2015-02-16 Thread Sven Drieling
Am Mon, 16 Feb 2015 18:00:41 +0200 schrieb Arvids Godjuks arvids.godj...@gmail.com: Hallo, Right now we need a breakthrough event - get type hints into the language at all. The most sensible thing to do it is to add basic type hints that work like the current conversion rules, maybe add some

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Pavel Kouřil
On Mon, Feb 16, 2015 at 5:42 PM, François Laupretre franc...@php.net wrote: Hi, - the fact that the RFC supports single types only, like the previous 'return type' RFC. While it is easier to implement, it opens several issues as multiply-typed arguments are an integral part of the PHP

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Benjamin Eberlei
On Mon, Feb 16, 2015 at 12:07 PM, Dmitry Stogov dmi...@zend.com wrote: hi, During discussion of different ways of implementing Design by Contract we got an idea of using annotations. BTW: annotations are useful by their own and may be used for different purposes. Support for annotations

Re: [PHP-DEV] Re: Annotations in PHP7

2015-02-16 Thread Dmitry Stogov
this won't implement features necessary for phpDocumentor, Doctrine, etc. On Mon, Feb 16, 2015 at 8:29 PM, Rowan Collins rowan.coll...@gmail.com wrote: On Mon, Feb 16, 2015 at 6:41 PM, Rowan Collins rowan.coll...@gmail.com mailto:rowan.coll...@gmail.com wrote: Is there any value in

Re: [PHP-DEV] Done something wrong ...

2015-02-16 Thread Lester Caine
On 16/02/15 18:34, Ferenc Kovacs wrote: On Mon, Feb 16, 2015 at 6:55 PM, Lester Caine les...@lsces.co.uk wrote: I've synced with current git and seem to have the files I expect for interbase, but when trying to run a clean build of the core stuff it no longer compiles ... For example

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Levi Morrison
On Mon, Feb 16, 2015 at 9:42 AM, François Laupretre franc...@php.net wrote: Hi, De : Arvids Godjuks [mailto:arvids.godj...@gmail.com] The 0.1 RFC version was mentioned a lot as a good compromise by many people and had major support. Maybe someone competent could pick it up, make necessary

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Derick Rethans
On Mon, 16 Feb 2015, Dmitry Stogov wrote: hi, During discussion of different ways of implementing Design by Contract we got an idea of using annotations. BTW: annotations are useful by their own and may be used for different purposes. Support for annotations was proposed long time ago:

Re: [PHP-DEV] Re: Annotations in PHP7

2015-02-16 Thread Rowan Collins
Dmitry Stogov wrote on 16/02/2015 18:41: this won't implement features necessary for phpDocumentor, Doctrine, etc. I know. Like I say, it's just a way of keeping things moving, rather than saying eh, maybe next year. It allows us to formally agree the feature, the roadmap, the basic

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Pavel Kouřil
On Mon, Feb 16, 2015 at 1:33 PM, Benjamin Eberlei kont...@beberlei.de wrote: On Mon, Feb 16, 2015 at 1:17 PM, Pavel Kouřil pajou...@gmail.com wrote: On Mon, Feb 16, 2015 at 12:07 PM, Dmitry Stogov dmi...@zend.com wrote: hi, During discussion of different ways of implementing Design by

RE: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread François Laupretre
Hi Dmitry De : Dmitry Stogov [mailto:dmi...@zend.com] I would propose exactly Andrea's 0.1. Most people were agree to support weak type hints by default. This proposal won't prevent feature addition of optional strict type hints. All are tired from endless arguing. Yes, but that's not

[PHP-DEV] Re: Annotations in PHP7

2015-02-16 Thread Yasuo Ohgaki
Hi Dmitry, On Mon, Feb 16, 2015 at 8:07 PM, Dmitry Stogov dmi...@zend.com wrote: During discussion of different ways of implementing Design by Contract we got an idea of using annotations. BTW: annotations are useful by their own and may be used for different purposes. Support for

[PHP-DEV] Re: Annotations in PHP7

2015-02-16 Thread Yasuo Ohgaki
Hi Dmitry, On Mon, Feb 16, 2015 at 8:07 PM, Dmitry Stogov dmi...@zend.com wrote: During discussion of different ways of implementing Design by Contract we got an idea of using annotations. BTW: annotations are useful by their own and may be used for different purposes. Support for

[PHP-DEV] Switch jumptable optimization

2015-02-16 Thread Bob Weinand
I'd like to show you my recent work on a jumptable optimization for switches. https://github.com/php/php-src/pull/1048 https://github.com/php/php-src/pull/1048 It is a fully transparent optimization of switches, by putting a new ZEND_SWITCH opcode at the top of the switch in case we can build

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Pavel Kouřil
On Mon, Feb 16, 2015 at 9:50 PM, François Laupretre franc...@php.net wrote: De : Pavel Kouril [mailto:pajou...@gmail.com] Hello, I know this is probably a pretty unpopular opinion in PHP (based on the replies I got in the other thread), but different values for parameters should be IMHO

RE: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread François Laupretre
De : Philip Sturgeon [mailto:pjsturg...@gmail.com] I know it is very easy for people to say Well, that v0.3 that I didn't like has been withdrawn, so let's just crack on and do some other new thing. It's not so easy. It would be easier to do as you suggest. And you can still do it in your

Re: [PHP-DEV] Done something wrong ...

2015-02-16 Thread Lester Caine
On 16/02/15 20:24, Martin Jansen wrote: OK I'm working off multiple local copies of the code base so vcsclean is not usable. I suspect it would wipe the eclipse project files anyway. IIRC vcsclean essentially runs `git clean -f -X`. That last parameter is important because it instructs git to

RE: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread François Laupretre
De : Pavel Kouril [mailto:pajou...@gmail.com] Hello, I know this is probably a pretty unpopular opinion in PHP (based on the replies I got in the other thread), but different values for parameters should be IMHO solved by method overloading and such. The question is not that it's

Re: [PHP-DEV] Re: Annotations in PHP7

2015-02-16 Thread Rafael Dohms
On Mon, Feb 16, 2015 at 7:41 PM, Dmitry Stogov dmi...@zend.com wrote: this won't implement features necessary for phpDocumentor, Doctrine, etc. Just be careful here with phpDocumentor, it does not use annotations but really needs docblocks instead. Today the overlap between it and doctrine and

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Pádraic Brady
On 16 February 2015 at 22:00, Philip Sturgeon pjsturg...@gmail.com wrote: I know it is very easy for people to say Well, that v0.3 that I didn't like has been withdrawn, so let's just crack on and do some other new thing. but I would have to ask people to consider that v0.3 had two thirds

RE: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Zeev Suraski
-Original Message- From: p...@golemon.com [mailto:p...@golemon.com] On Behalf Of Sara Golemon Sent: Tuesday, February 17, 2015 1:58 AM To: franc...@php.net Cc: Philip Sturgeon; Arvids Godjuks; Jefferson Gonzalez; Rowan Collins; PHP internals Subject: Re: [PHP-DEV] Reviving scalar

Re: [PHP-DEV] Proposing [constructive] solutions (was: I quit)

2015-02-16 Thread Kris Craig
On Mon, Feb 16, 2015 at 7:48 PM, Larry Garfield la...@garfieldtech.com wrote: On 02/16/2015 10:31 AM, François Laupretre wrote: - The leadership of the language is left to consensus, so that when consensus cannot be reached, someone has to take on the role of mediator / chairman / leader

Re: [PHP-DEV] Switch jumptable optimization

2015-02-16 Thread Dmitry Stogov
On Tue, Feb 17, 2015 at 2:04 AM, Bob Weinand bobw...@hotmail.com wrote: I'd like to show you my recent work on a jumptable optimization for switches. https://github.com/php/php-src/pull/1048 https://github.com/php/php-src/pull/1048 It is a fully transparent optimization of switches, by

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Dmitry Stogov
Hi Nikita, On Tue, Feb 17, 2015 at 12:07 AM, Nikita Popov nikita@gmail.com wrote: On Mon, Feb 16, 2015 at 10:02 PM, Dmitry Stogov dmi...@zend.com wrote: On Mon, Feb 16, 2015 at 11:05 PM, Benjamin Eberlei kont...@beberlei.de wrote: On Mon, Feb 16, 2015 at 12:07 PM, Dmitry Stogov

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Andrey Andreev
Hi, On Mon, Feb 16, 2015 at 8:56 PM, Dmitry Stogov dmi...@zend.com wrote: I would propose exactly Andrea's 0.1. Most people were agree to support weak type hints by default. This proposal won't prevent feature addition of optional strict type hints. Sorry, but I'll have to repeat what has

Re: [PHP-DEV] Switch jumptable optimization

2015-02-16 Thread Joe Watkins
Very clever ... thanks bob :) Cheers Joe On Tue, Feb 17, 2015 at 6:46 AM, Dmitry Stogov dmi...@zend.com wrote: On Tue, Feb 17, 2015 at 2:04 AM, Bob Weinand bobw...@hotmail.com wrote: I'd like to show you my recent work on a jumptable optimization for switches.

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Dennis Birkholz
Am 16.02.2015 um 21:39 schrieb François Laupretre: If we deprecate using bare class names as type hints and replace it with the 'object(classname)' syntax, we can reserve keywords for 7.0 and, maybe 7.1 but potential name clashes should be away in 7.2. This is a huge BC break and will

Re: [PHP-DEV] Switch jumptable optimization

2015-02-16 Thread Rasmus Lerdorf
On 02/16/2015 03:47 PM, Bob Weinand wrote: Am 17.02.2015 um 00:30 schrieb Rasmus Lerdorf ras...@lerdorf.com mailto:ras...@lerdorf.com: On 02/16/2015 03:04 PM, Bob Weinand wrote: I'd like to show you my recent work on a jumptable optimization for switches.

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Pascal Chevrel
Le 16/02/2015 23:50, François Laupretre a écrit : So, IMO, the RFC is dead, whatever 2/3 or 3/4 we may have. Once it was clear that both camps would never agree, with every PHP founders against it, pushing it was useless. We're not electing a president, we're trying to ensure we make the right

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Arvids Godjuks
Might I remind everyone that time is not on our side here - feature freeze is looming and actual work has to be done. The part you must understand is: Strict type hints are possible if someone cares to implement them with a next RFC. Be our guest. Right now we need to sort out the basic stuff -

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Nikita Popov
On Tue, Feb 17, 2015 at 12:58 AM, Sara Golemon poll...@php.net wrote: On Mon, Feb 16, 2015 at 2:50 PM, François Laupretre franc...@php.net wrote: Once again, anyone can take over version 0.3, if it is so great. Why don't you do it ? I will play the game, stop working on my proposal, and

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Sara Golemon
On Mon, Feb 16, 2015 at 4:52 PM, Rasmus Lerdorf ras...@lerdorf.com wrote: I still disagree strongly that it serves everyone's needs. The internal API and APIs provided by extensions are completely messed up by this approach. Userspace authors get the choice when they write their code. Even if

Re: [PHP-DEV] Switch jumptable optimization

2015-02-16 Thread Rasmus Lerdorf
On 02/16/2015 03:04 PM, Bob Weinand wrote: I'd like to show you my recent work on a jumptable optimization for switches. https://github.com/php/php-src/pull/1048 https://github.com/php/php-src/pull/1048 It is a fully transparent optimization of switches, by putting a new ZEND_SWITCH

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Dan Ackroyd
On 16 February 2015 at 22:50, François Laupretre franc...@php.net wrote: it is clear that we don't have consensus on this topic. So, IMO, the RFC is dead, whatever 2/3 or 3/4 we may have. It's okay for people to disagree about things. And we have voting to allow us to resolve those

Re: [PHP-DEV] Switch jumptable optimization

2015-02-16 Thread Bob Weinand
Am 17.02.2015 um 00:30 schrieb Rasmus Lerdorf ras...@lerdorf.com: On 02/16/2015 03:04 PM, Bob Weinand wrote: I'd like to show you my recent work on a jumptable optimization for switches. https://github.com/php/php-src/pull/1048 https://github.com/php/php-src/pull/1048 It is a fully

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Dan Ackroyd
On 17 February 2015 at 00:22, Nikita Popov nikita@gmail.com wrote: Thank you for taking over. I like use strict and declare as top-level only most. That would be this no vote changed to a yes. And I'd also like to say thank you Sara for taking over. cheers Dan -- PHP Internals - PHP

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Rasmus Lerdorf
On 02/16/2015 03:58 PM, Sara Golemon wrote: On Mon, Feb 16, 2015 at 2:50 PM, François Laupretre franc...@php.net wrote: Once again, anyone can take over version 0.3, if it is so great. Why don't you do it ? I will play the game, stop working on my proposal, and vote 'yes' again. But don't

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Stelian Mocanita
Thanks Sara for taking over, For myself both ?php strict would seal the deal, but use strict; is also an option I would endorse. Despite mentioning not scoping union types, I feel like a numeric type would make a lot of sense and bring in more consensus to the list, fixing the all famous sin()

[PHP-DEV] Re: Proposing [constructive] solutions (was: I quit)

2015-02-16 Thread Rowan Collins
Hi Francois, Between my day job and my local user group meetup, I haven't had as much time as I'd like to read and respond to this. You've got some great suggestions here, though, so I'm going to rush through and add some thoughts before I go to bed. On 16 February 2015 at 15:31, François

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Drew Paroski
On Mon, Feb 16, 2015 at 4:52 PM, Rasmus Lerdorf ras...@lerdorf.com wrote: On 02/16/2015 03:58 PM, Sara Golemon wrote: On Mon, Feb 16, 2015 at 2:50 PM, François Laupretre franc...@php.net wrote: Once again, anyone can take over version 0.3, if it is so great. Why don't you do it ? I will play

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Sara Golemon
On Mon, Feb 16, 2015 at 2:50 PM, François Laupretre franc...@php.net wrote: Once again, anyone can take over version 0.3, if it is so great. Why don't you do it ? I will play the game, stop working on my proposal, and vote 'yes' again. But don't ask me to do it in your place. If nobody else

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Benjamin Eberlei
On Mon, Feb 16, 2015 at 1:14 PM, Alexander Lisachenko lisachenko...@gmail.com wrote: 2015-02-16 15:12 GMT+03:00 Benjamin Eberlei kont...@beberlei.de: but what is the API of an AST node and how does the visitor look like? I have a draft for that:

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Dmitry Stogov
We don't have final design yet. just idea(s) and a question - should we try to do it for PHP7 or later or not at all. Thanks. Dmitry. On Mon, Feb 16, 2015 at 3:43 PM, Cesar Rodas ce...@rodas.me wrote: On 16/02/15 13:40, Alexander Lisachenko wrote: 2015-02-16 15:31 GMT+03:00 Benjamin

Re: [PHP-DEV] PHP JIT or AOT

2015-02-16 Thread Dmitry Stogov
The type checks in PHP7 is quite cheap (2-3 CPU instructions). Strict or weak check doesn't make any difference for fast path (the same 2-3 instructions). The slow patch for weak checks is going to be a bit more expensive. Well, not really. It's 2-3 CPU instructions once you have the

Re: [PHP-DEV] PHP JIT or AOT

2015-02-16 Thread Anthony Ferrara
Dmitry, On Mon, Feb 16, 2015 at 9:12 AM, Dmitry Stogov dmi...@zend.com wrote: The type checks in PHP7 is quite cheap (2-3 CPU instructions). Strict or weak check doesn't make any difference for fast path (the same 2-3 instructions). The slow patch for weak checks is going to be a bit more

[PHP-DEV] Re: Reviving scalar type hints

2015-02-16 Thread Theodore Brown
On Mon, Feb 16, 2015 at 18:58, Sara Golemon poll...@php.net wrote: If nobody else does it, I will. I think Andrea's 0.3 proposal was extremely well balanced, served everyone's needs whether they would admit it or not, and who's only failing (subjectively termed) was the use of declare().  I

Re: [PHP-DEV] Proposing [constructive] solutions (was: I quit)

2015-02-16 Thread Larry Garfield
On 02/16/2015 10:31 AM, François Laupretre wrote: - The leadership of the language is left to consensus, so that when consensus cannot be reached, someone has to take on the role of mediator / chairman / leader for the feature, and try to push through a compromise. I have no democratic

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Larry Garfield
On 02/16/2015 06:58 PM, Sara Golemon wrote: On Mon, Feb 16, 2015 at 2:50 PM, François Laupretre franc...@php.net wrote: Once again, anyone can take over version 0.3, if it is so great. Why don't you do it ? I will play the game, stop working on my proposal, and vote 'yes' again. But don't ask

RE: [PHP-DEV] Re: Annotations in PHP7

2015-02-16 Thread François Laupretre
Hi Dmitry, In my mind, annotation syntax was one level lower, dealing with strings of unknown syntax, not PHP expressions. Something like : '*' whitespaces '@' STRING free-string-up-to-eol This supports : * @requires $a 0 But also : * @statement INSERT INTO ?? VALUES (13, 'Phoenix', 'AZ',

RE: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread François Laupretre
De : Pascal Chevrel [mailto:pascal.chev...@free.fr] Does it mean that in your mind the founders of the PHP language (basically Rasmus/Zeev/Andy) have a veto right on any RFC just because they are the founders, like in a company with shareholders? If out of 100 votes for a feature, 97 were

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Pavel Kouřil
On Mon, Feb 16, 2015 at 12:07 PM, Dmitry Stogov dmi...@zend.com wrote: hi, During discussion of different ways of implementing Design by Contract we got an idea of using annotations. BTW: annotations are useful by their own and may be used for different purposes. Support for annotations was

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Benjamin Eberlei
On Mon, Feb 16, 2015 at 1:17 PM, Pavel Kouřil pajou...@gmail.com wrote: On Mon, Feb 16, 2015 at 12:07 PM, Dmitry Stogov dmi...@zend.com wrote: hi, During discussion of different ways of implementing Design by Contract we got an idea of using annotations. BTW: annotations are useful

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Alexander Lisachenko
2015-02-16 15:31 GMT+03:00 Benjamin Eberlei kont...@beberlei.de: My question is how do i evaluate this at runtime? I suppose a function is necessary like evaluate_ast(...), but that requires passing the context. many many open questions and as nikic points out this should probably be

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Cesar Rodas
On 16/02/15 14:00, Dmitry Stogov wrote: We don't have final design yet. just idea(s) and a question - should we try to do it for PHP7 or later or not at all. That is awesome. I would vote for a yes and I'd like it out ASAP (I would adapt my own annotation parser to read *also* this

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Cesar Rodas
On 16/02/15 13:40, Alexander Lisachenko wrote: 2015-02-16 15:31 GMT+03:00 Benjamin Eberlei kont...@beberlei.de: My question is how do i evaluate this at runtime? I suppose a function is necessary like evaluate_ast(...), but that requires passing the context. many many open questions and as

[PHP-DEV] Re: Annotations in PHP7

2015-02-16 Thread Dmitry Stogov
The implementation is not going to be simple, and taking in account other tasks, it may be difficult to provide high-quality implementation. Lets look if it's really a desirable feature. Then I may do all my best, or forget about it by 7.1. Thanks. Dmitry. On Mon, Feb 16, 2015 at 3:14 PM, Nikita

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Dmitry Stogov
our approach is more powerfull, and HHVM syntax is not sufficient. Also somethig looks better than something. anyway, syntax decorators are discussable. Thanks. Dmitry. On Mon, Feb 16, 2015 at 3:19 PM, Dennis Birkholz den...@birkholz.biz wrote: Hi, Am 16.02.2015 um 12:07 schrieb Dmitry

Re: [PHP-DEV] I quit.

2015-02-16 Thread Rowan Collins
François Laupretre wrote on 16/02/2015 12:27: De : Rowan Collins [mailto:rowan.coll...@gmail.com] Please can we take Andrea at her word: This isn’t a judgement of the PHP community nor the internals mailing list, you’re all wonderful people and it’s really been a pleasure, and I mean that

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Alexander Lisachenko
2015-02-16 15:12 GMT+03:00 Benjamin Eberlei kont...@beberlei.de: but what is the API of an AST node and how does the visitor look like? I have a draft for that: https://gist.github.com/lisachenko/ffcfdec4c46e01864b33 This is extended version for php-ast extension that I want to propose for

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Dennis Birkholz
Hi, Am 16.02.2015 um 12:07 schrieb Dmitry Stogov: HHVM already implemented similar concept http://docs.hhvm.com/manual/en/hack.attributes.php Why not borrow their syntax? Makes it easier to write stuff for both languages. Greets, Dennis -- PHP Internals - PHP Runtime Development Mailing

Re: [PHP-DEV] Spaceship operator RFC

2015-02-16 Thread Andrea Faulds
Hi Stas, On 16 Feb 2015, at 05:20, Stanislav Malyshev smalys...@gmail.com wrote: Since Andrea has withdrawn the spaceship operator RFC (https://wiki.php.net/rfc/combined-comparison-operator), I'd like to resurrect it. Looks like by vote results (with 1 day of official vote left) it was

Re: [PHP-DEV] PHP JIT or AOT

2015-02-16 Thread Anthony Ferrara
Dmitry and Joe, On Mon, Feb 16, 2015 at 1:59 AM, Dmitry Stogov dmi...@zend.com wrote: On Mon, Feb 16, 2015 at 12:45 AM, Anthony Ferrara ircmax...@gmail.com wrote: Well, if you know the destination function at compile time, you don't need to generate generic code. you can generate a direct

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Dmitry Stogov
On Mon, Feb 16, 2015 at 10:57 PM, Derick Rethans der...@php.net wrote: On Mon, 16 Feb 2015, Dmitry Stogov wrote: hi, During discussion of different ways of implementing Design by Contract we got an idea of using annotations. BTW: annotations are useful by their own and may be used

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Dmitry Stogov
On Mon, Feb 16, 2015 at 11:05 PM, Benjamin Eberlei kont...@beberlei.de wrote: On Mon, Feb 16, 2015 at 12:07 PM, Dmitry Stogov dmi...@zend.com wrote: hi, During discussion of different ways of implementing Design by Contract we got an idea of using annotations. BTW: annotations are

Re: [PHP-DEV] Annotations in PHP7

2015-02-16 Thread Nikita Popov
On Mon, Feb 16, 2015 at 10:02 PM, Dmitry Stogov dmi...@zend.com wrote: On Mon, Feb 16, 2015 at 11:05 PM, Benjamin Eberlei kont...@beberlei.de wrote: On Mon, Feb 16, 2015 at 12:07 PM, Dmitry Stogov dmi...@zend.com wrote: hi, During discussion of different ways of implementing Design by

[PHP-DEV] Re: Annotations in PHP7

2015-02-16 Thread Dmitry Stogov
On Tue, Feb 17, 2015 at 1:15 AM, Yasuo Ohgaki yohg...@ohgaki.net wrote: Hi Dmitry, On Mon, Feb 16, 2015 at 8:07 PM, Dmitry Stogov dmi...@zend.com wrote: During discussion of different ways of implementing Design by Contract we got an idea of using annotations. BTW: annotations are useful

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Sara Golemon
On Mon, Feb 16, 2015 at 6:55 PM, Rasmus Lerdorf ras...@lerdorf.com wrote: I would very much like it to be my problem how my API is exposed to a user. At the very least I should have as much control over an API written in C as one written in PHP. And you have that control. You expose

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Sara Golemon
On Mon, Feb 16, 2015 at 10:04 PM, Zeev Suraski z...@zend.com wrote: That syntax poll aside, I had what I hope is some sort an enlightenment, and I think I know what will get me to cast my vote in favor of 'strict', as a true supporter. There's one very special conversion that's too common in

Re: [PHP-DEV] Reviving scalar type hints

2015-02-16 Thread Zeev Suraski
In a word, yes. Have to say you're abilities to compile Zeev - formal declaration are pretty amazing :) Zeev On 17 בפבר׳ 2015, at 08:20, Sara Golemon poll...@php.net wrote: On Mon, Feb 16, 2015 at 10:04 PM, Zeev Suraski z...@zend.com wrote: That syntax poll aside, I had what I hope is

Re: [PHP-DEV] Re: Annotations in PHP7

2015-02-16 Thread Dmitry Stogov
On Tue, Feb 17, 2015 at 6:45 AM, François Laupretre franc...@php.net wrote: Hi Dmitry, In my mind, annotation syntax was one level lower, dealing with strings of unknown syntax, not PHP expressions. Something like : '*' whitespaces '@' STRING free-string-up-to-eol This supports : *

Re: [PHP-DEV] I quit.

2015-02-16 Thread Arvids Godjuks
The 0.1 RFC version was mentioned a lot as a good compromise by many people and had major support. Maybe someone competent could pick it up, make necessary adjustments that where required and let people vote on it? Start with small steps - get the weak type hints into the language first, see how

Re: [PHP-DEV] I quit.

2015-02-16 Thread Jefferson Gonzalez
You're right. I am probably expressing my own frustration when I imagine that withdrawing four important RFC s a few days before vote ends has little to do with time management issues. Let's stay politically correct and don't express anything about the atmosphere in the community, which has

[PHP-DEV] Re: Annotations in PHP7

2015-02-16 Thread Pierre Joye
On Mon, Feb 16, 2015 at 3:07 AM, Dmitry Stogov dmi...@zend.com wrote: hi, During discussion of different ways of implementing Design by Contract we got an idea of using annotations. Thanks a lot to push that forward! BTW: annotations are useful by their own and may be used for different

[PHP-DEV] Re: I quit.

2015-02-16 Thread Daniel Lowrey
The 0.1 RFC version was mentioned a lot as a good compromise by many people and had major support. People keep saying this like it's a thing, but I and others are vehemently opposed to this as a solution. The only thing weak hints accomplishes is the illusion of safety without actually

RE: [PHP-DEV] Re: I quit.

2015-02-16 Thread Zeev Suraski
-Original Message- From: rdlow...@gmail.com [mailto:rdlow...@gmail.com] On Behalf Of Daniel Lowrey Sent: Monday, February 16, 2015 5:13 PM To: internals@lists.php.net Subject: [PHP-DEV] Re: I quit. The 0.1 RFC version was mentioned a lot as a good compromise by many people and

Re: [PHP-DEV] Re: I quit.

2015-02-16 Thread Daniel Lowrey
On Mon, Feb 16, 2015 at 10:19 AM, Zeev Suraski z...@zend.com wrote: -Original Message- From: rdlow...@gmail.com [mailto:rdlow...@gmail.com] On Behalf Of Daniel Lowrey Sent: Monday, February 16, 2015 5:13 PM To: internals@lists.php.net Subject: [PHP-DEV] Re: I quit. The

[PHP-DEV] Proposing [constructive] solutions (was: I quit)

2015-02-16 Thread François Laupretre
De : Rowan Collins [mailto:rowan.coll...@gmail.com] Saying that's enough isn't even a productive comment. Enough what? What is it you are asking to happen next? Maybe an initiative to write an RFC about the rules we should follow when writing to the list. People who agree could show their

Re: [PHP-DEV] Remove $this from incompatible context

2015-02-16 Thread Rowan Collins
Stanislav Malyshev wrote on 16/02/2015 05:14: Hi! Agreed. Personally, I'm a great fan of symettry, so part of me would prefer to introduce a keyword for when you *can't* call a method statically, e.g. instance function foo() { ... }. But I guess instance This would be another form of saying

Re: [PHP-DEV] RFC: Expectations

2015-02-16 Thread Joe Watkins
is there any penalty of catch-AssertionException-blocks? Are those eliminated in production code? Assertions should never be enabled in production code, the ability to catch (and enable by configuration) the exception serves the developer of the code during development only. The example code is

Re: [PHP-DEV] A modest proposal: __contructStatic

2015-02-16 Thread Rowan Collins
Kris Craig wrote on 16/02/2015 01:40: create the static instance Isn't that essentially a contradiction in terms? I can't help but feel that blurring the line between static and non-static classes/methods would cause more harm than good. I've never really done any work with Redis before

RE: [PHP-DEV] [VOTE] Scalar Type Hints

2015-02-16 Thread François Laupretre
De : Netroby [mailto:hufeng1...@gmail.com] We do not have Scalar type hints for years. we code in php for years without any type check. it's ok. not the primary things. Look at other dynamic programming language, they may not have the type check either. It is ok, and it is fine.

Re: [PHP-DEV] [RFC] Exceptions in the engine

2015-02-16 Thread Rowan Collins
Tony Marston wrote on 16/02/2015 10:09: This RFC only mentions errors with object methods, so what impact would it have with procedural functions. For example, if fopen('nonexistantfile.txt') fails the return value is FALSE and an E_WARNING is generated, but it is difficult to trap the error

  1   2   >