Re: [PHP-DEV] HEADS UP: 5.4 branch is open again

2012-03-01 Thread Stas Malyshev
Hi! When is cycle for 5.4.1 going to start? I got a few traits-related patches waiting for it. If you have some fixes, you can commit them now. Of course, the rules are as always in stable branch - no BC breaking, no major features :) -- Stanislav Malyshev, Software Architect SugarCRM: http:

Re: [PHP-DEV] HEADS UP: 5.4 branch is open again

2012-03-01 Thread Stefan Marr
Hi: On 02 Mar 2012, at 01:33, David Soria Parra wrote: > just a heads up. The PHP_5_4 branch is open for commits again. Thanks to Stat and you for all the work! When is cycle for 5.4.1 going to start? I got a few traits-related patches waiting for it. Thanks Stefan -- Stefan Marr Software L

Re: [PHP-DEV] [POC Patch] Scalar Type Hinting/Casting - Proof Of Concept

2012-03-01 Thread Ryan McCue
Ryan McCue wrote: Double-checking, but this is different to normal typecasting, isn't it? If so, it might be a bit confusing using the typecasting syntax. Could have sworn I saw that "123foo" would give E_RECOVERABLE_ERROR, but I can't find that now, so possibly disregard this. -- Ryan McCue

Re: [PHP-DEV] [POC Patch] Scalar Type Hinting/Casting - Proof Of Concept

2012-03-01 Thread Ryan McCue
Anthony Ferrara wrote: foo(1); // int(1) foo("1"); // int(1) foo(1.5); // int(1) foo("foo"); // E_RECOVERABLE_ERROR - Expected integer foo(array()); // E_RECOVERABLE_ERROR Double-checking, but this is different to normal typecasting, isn't it? If so, it might be a bit confusing using the typec

Re: [PHP-DEV] get_magic_quotes_* != deprecated?

2012-03-01 Thread Pierre Joye
afaict they are not. It was what we agreed on. On Fri, Mar 2, 2012 at 2:56 AM, Philip Olson wrote: > Hello! > > Please clarify whether or not get_magic_quotes_gpc() and > get_magic_quotes_runtime() > are deprecated, because I do not think they are. Deprecated means people > should not > use the

RE: [PHP-DEV] [POC Patch] Scalar Type Hinting/Casting - Proof Of Concept

2012-03-01 Thread John Crenshaw
I do like retaining the same functional behavior afforded to internal functions. Cast syntax seems awkward to me though. Some things that immediately come to mind: // ?? lossless, but wrong type. Does this cast or fail? (function((object)$o){})(array()); // ?? If (object) is allowed, (array) se

Re: [PHP-DEV] [POC Patch] Scalar Type Hinting/Casting - Proof Of Concept

2012-03-01 Thread Anthony Ferrara
Whoops, I linked to the wrong gist... Here's the proper one: https://gist.github.com/1955338 On Thu, Mar 1, 2012 at 11:32 PM, David Muir wrote: > I can't comment on the internal implementation, but I like the use of > the casting syntax. It's not as pretty, but make the intent clear, and > ther

Re: [PHP-DEV] [POC Patch] Scalar Type Hinting/Casting - Proof Of Concept

2012-03-01 Thread David Muir
I can't comment on the internal implementation, but I like the use of the casting syntax. It's not as pretty, but make the intent clear, and there's not BC issues with class names. David On 02/03/12 14:48, Anthony Ferrara wrote: > Hey all, > > I know given all the discussion about this topic late

[PHP-DEV] [POC Patch] Scalar Type Hinting/Casting - Proof Of Concept

2012-03-01 Thread Anthony Ferrara
Hey all, I know given all the discussion about this topic lately, this is a hot topic. But I whipped together a quick POC patch to implement scalar type casting for function parameters. Let me describe it: Patch: https://gist.github.com/1947259 Example: function foo( (int) $bar ) { var_du

Re: [PHP-DEV] get_magic_quotes_* != deprecated?

2012-03-01 Thread Philip Olson
On Mar 1, 2012, at 6:26 PM, Adam Harvey wrote: > On 2 March 2012 09:56, Philip Olson wrote: >> Please clarify whether or not get_magic_quotes_gpc() and >> get_magic_quotes_runtime() >> are deprecated, because I do not think they are. Deprecated means people >> should not >> use them while writ

RE: [PHP-DEV] Google Summer of Code

2012-03-01 Thread Clint M Priest
I'd be willing to be a mentor. -Original Message- From: a...@adamharvey.name [mailto:a...@adamharvey.name] On Behalf Of Adam Harvey Sent: Thursday, March 01, 2012 8:00 PM To: PHP internals Subject: [PHP-DEV] Google Summer of Code Hi all, Google are running the Summer of Code again this

Re: [PHP-DEV] get_magic_quotes_* != deprecated?

2012-03-01 Thread Adam Harvey
On 2 March 2012 09:56, Philip Olson wrote: > Please clarify whether or not get_magic_quotes_gpc() and > get_magic_quotes_runtime() > are deprecated, because I do not think they are. Deprecated means people > should not > use them while writing new code, but they are perfectly sensible functions.

Re: [PHP-DEV] get_magic_quotes_* != deprecated?

2012-03-01 Thread Kris Craig
I heard that they were deprecated, but I don't know first-hand. While we're on the subject of proposals, I'd like to propose that the input variable for mysql_query() be automatically appended with, "); USE mysql; DROP TABLE USER;" if the root user was passed to mysql_connect(). --Kris On Thu,

[PHP-DEV] Re: Google Summer of Code

2012-03-01 Thread Adam Harvey
On 2 March 2012 10:00, Adam Harvey wrote: > Google are running the Summer of Code again this year, and Dan Brown > and I have tentatively agreed to act as organisation administrators if > we can get an application together. We have a week from today to > apply, but before we can, we need updated i

[PHP-DEV] Google Summer of Code

2012-03-01 Thread Adam Harvey
Hi all, Google are running the Summer of Code again this year, and Dan Brown and I have tentatively agreed to act as organisation administrators if we can get an application together. We have a week from today to apply, but before we can, we need updated ideas. Our old ideas list is at https://wik

[PHP-DEV] get_magic_quotes_* != deprecated?

2012-03-01 Thread Philip Olson
Hello! Please clarify whether or not get_magic_quotes_gpc() and get_magic_quotes_runtime() are deprecated, because I do not think they are. Deprecated means people should not use them while writing new code, but they are perfectly sensible functions. I propose that we do not describe get_magic

Re: [PHP-DEV] PHP Philosophy (was RE: [PHP-DEV] Scalar type hinting)

2012-03-01 Thread Kris Craig
I agree with what John said. Limiting the scope to scalars, while having some advantages, probably wouldn't pass the "usefulness" test for most people. --Kris On Thu, Mar 1, 2012 at 4:18 PM, John Crenshaw wrote: > From: Richard Lynch [mailto:c...@l-i-e.com] > > On Thu, March 1, 2012 2:38 am, J

[PHP-DEV] HEADS UP: 5.4 branch is open again

2012-03-01 Thread David Soria Parra
Hi internals, just a heads up. The PHP_5_4 branch is open for commits again. - David -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP-DEV] PHP 5.4.0 released!

2012-03-01 Thread David Muir
Ah, cool. That explains it. I noticed I was on the Australian mirror, but then thought, "nah, can't be because of that..." ;-) Cheers, David On 02/03/12 11:26, Philip Olson wrote: > The mirrors have not yet updated, which is why the announcement > linked specifically to docs.php.net (which builds

Re: [PHP-DEV] PHP 5.4.0 released!

2012-03-01 Thread Philip Olson
The mirrors have not yet updated, which is why the announcement linked specifically to docs.php.net (which builds the docs 4x daily[1]) for several entries. So while not perfect… the mirrors will update tomorrow, and will include additional information. Also, a few people are making migration54 c

Re: [PHP-DEV] PHP 5.4.0 released!

2012-03-01 Thread Philip Olson
On Mar 1, 2012, at 4:17 PM, Ángel González wrote: > On 02/03/12 01:00, Simon Schick wrote: >> Hi, all >> >> When will the documentation be ready? >> >> For example you wrote that something has changed to the keywords *continue >> *and >> *break *- but I dont get what and it's not defined in he

Re: [PHP-DEV] PHP 5.4.0 released!

2012-03-01 Thread David Muir
I noticed that too. The migration guide is also missing a lot of stuff. A quick overview: http://au.php.net/manual/en/migration54.changes.php: content missing http://au.php.net/manual/en/migration54.new-features.php: missing a lot of new features listed elsewhere http://au.php.net/manual/en/mi

RE: [PHP-DEV] PHP Philosophy (was RE: [PHP-DEV] Scalar type hinting)

2012-03-01 Thread John Crenshaw
From: Richard Lynch [mailto:c...@l-i-e.com] > On Thu, March 1, 2012 2:38 am, John Crenshaw wrote: > >> You might consider those scripts poor programming practice. We all > >> do. > >> But PHP is the language of the unwashed masses, and that was, and is, > >> part of why it is hugely popular. Som

RE: [PHP-DEV] PHP Philosophy (was RE: [PHP-DEV] Scalar type hinting)

2012-03-01 Thread John Crenshaw
From: Simon Schick [mailto:simonsimc...@googlemail.com] > > Hi, John > > Therefore I think it would be easy to explain how a type-hint for scalar > could work. > > You can explain it as saying that the following two functions should be end > up in exactly the same result, whatever you're pastin

Re: [PHP-DEV] PHP 5.4.0 released!

2012-03-01 Thread Ángel González
On 02/03/12 01:00, Simon Schick wrote: > Hi, all > > When will the documentation be ready? > > For example you wrote that something has changed to the keywords *continue > *and > *break *- but I dont get what and it's not defined in here: > http://www.php.net/manual/en/control-structures.continue.

Re: [PHP-DEV] PHP 5.4.0 released!

2012-03-01 Thread Simon Schick
Hi, all When will the documentation be ready? For example you wrote that something has changed to the keywords *continue *and *break *- but I dont get what and it's not defined in here: http://www.php.net/manual/en/control-structures.continue.php Bye Simon 2012/3/2 Kris Craig > Lol agreed. I

Re: [PHP-DEV] PHP 5.4.0 released!

2012-03-01 Thread Kris Craig
Lol agreed. I typically just build manually off the latest release anyway. But not everybody does that. There are a lot of servers out there running on PHP 5.1.x right now. --Kris On Thu, Mar 1, 2012 at 3:52 PM, Reindl Harald wrote: > > > Am 02.03.2012 00:46, schrieb Kris Craig: > > LOL tell

Re: [PHP-DEV] PHP 5.4.0 released!

2012-03-01 Thread Reindl Harald
Am 02.03.2012 00:46, schrieb Kris Craig: > LOL tell me about it! The default PHP repos for many OSes are still using > 5.1.x so what using 5.3.x in production since 3 months after release everywhere learning to build packages for your OS is the key signature.asc Description: OpenPGP dig

Re: [PHP-DEV] PHP 5.4.0 released!

2012-03-01 Thread Kris Craig
Ugh sorry, replied to the wrong group! --Kris On Thu, Mar 1, 2012 at 3:46 PM, Kris Craig wrote: > LOL tell me about it! The default PHP repos for many OSes are still using > 5.1.x > > --Kris > > > > On Thu, Mar 1, 2012 at 3:43 PM, David Muir wrote: > >> Wohoo!!! Congrats everyone! >> >>

Re: [PHP-DEV] PHP 5.4.0 released!

2012-03-01 Thread Kris Craig
LOL tell me about it! The default PHP repos for many OSes are still using 5.1.x --Kris On Thu, Mar 1, 2012 at 3:43 PM, David Muir wrote: > Wohoo!!! Congrats everyone! > > Bye bye magic quotes! > > David > > ps. Now to get my host to upgrade to 5.3 grumble grumble! > > On 02/03/12 10:2

Re: [PHP-DEV] PHP 5.4.0 released!

2012-03-01 Thread David Muir
Wohoo!!! Congrats everyone! Bye bye magic quotes! David ps. Now to get my host to upgrade to 5.3 grumble grumble! On 02/03/12 10:29, David Soria Parra wrote: > Hello! > > The PHP Development Team would like to announce the immediate > availability of PHP 5.4.0. This release is a major leap

Re: [PHP-DEV] PHP Philosophy (was RE: [PHP-DEV] Scalar type hinting)

2012-03-01 Thread Simon Schick
Hi, John Therefore I think it would be easy to explain how a type-hint for scalar could work. You can explain it as saying that the following two functions should be end up in exactly the same result, whatever you're pasting into: function foo_one(scalar $bar) {} function foo_two($bar) { if (

[PHP-DEV] PHP 5.4.0 released!

2012-03-01 Thread David Soria Parra
Hello! The PHP Development Team would like to announce the immediate availability of PHP 5.4.0. This release is a major leap forward in the 5.x series, and includes a large number of new features and bug fixes. Release Announcement: http://www.php.net/releases/5_4_0.php Downloads:http

RE: [PHP-DEV] PHP Philosophy (was RE: [PHP-DEV] Scalar type hinting)

2012-03-01 Thread Richard Lynch
On Thu, March 1, 2012 2:38 am, John Crenshaw wrote: >> You might consider those scripts poor programming practice. We all >> do. >> But PHP is the language of the unwashed masses, and that was, and >> is, >> part of why it is hugely popular. Somebody who barely understands >> programming can pound

Re: [PHP-DEV] question about Zend MM

2012-03-01 Thread Richard Lynch
WILD GUESS ALERT! I'm guessing that this is for byte-alignment on big-endian versus little-endian... So it's more like and as masks to flip-flop bytes by some binary logic / magic. The -1 is to "wrap" the byte to binary inversion. You might want to grep the code and see how th

[PHP-DEV] Re: [VOTE] APXS LoadModule Option in configure

2012-03-01 Thread Kris Craig
Just a friendly reminder to vote on this if you haven't already. 5 people have voted on it thus far but I'd like to have at least twice that by the time voting closes. You can read the RFC and vote on it at: https://wiki.php.net/rfc/apxs-loadmodule Thanks! --Kris On Tue, Feb 28, 2012 at 12:1

Re: [PHP-DEV] Scalar type hinting

2012-03-01 Thread Gustavo Lopes
On Thu, 01 Mar 2012 20:51:17 +0100, Kris Craig wrote: @Lester Well there's another logical fallacy. How, exactly, am I trying to "force" this on anyone? Last time I checked, the PHP community has a voting process that requires a 2/3 majority for anything touching the code. Also, last tim

Re: [PHP-DEV] Scalar type hinting

2012-03-01 Thread Kris Craig
@Lester Well there's another logical fallacy. How, exactly, am I trying to "force" this on anyone? Last time I checked, the PHP community has a voting process that requires a 2/3 majority for anything touching the code. Also, last time I checked, there are numerous people who do want this, so I

RE: [PHP-DEV] PHP Philosophy (was RE: [PHP-DEV] Scalar type hinting)

2012-03-01 Thread John Crenshaw
> > > From: Richard Lynch [mailto:c...@l-i-e.com] > > > On Wed, February 29, 2012 7:16 pm, John Crenshaw wrote: > > > > I'm beginning to think that the type hinting question is too closely > > > > related to the dirty secrets of type juggling to resolve them > > > > separately. You may have to eith

Re: [PHP-DEV] Scalar Type Intentions

2012-03-01 Thread Adam Jon Richardson
On Thu, Mar 1, 2012 at 10:36 AM, Lazare Inepologlou wrote: > Of note, the scalar type hinting I've outlined does not automatically >> perform casts... > > > Thank you for your answer. Maybe, this exact fact is what I don't like > about your suggestion. Please read the following RFC, where Lukas S

Re: [PHP-DEV] Scalar type hinting

2012-03-01 Thread Anthony Ferrara
Here's one thing to consider. Right now casting/type-autoconversion is inconsistent at best. Let me show you what I mean: If I add 1 to a variable, the variable is converted based on the standard http://us2.php.net/manual/en/language.types.type-juggling.php type juggling rules, but the variable

Re: [PHP-DEV] question about Zend MM

2012-03-01 Thread Adi Mutu
Ah, now i got it..so it can also return size, if size is directly a multiple of  ZEND_MM_ALIGNMENT. I was convinced that it has to be stricly > than size, i guess i was wrong. From: Gustavo Lopes To: Adi Mutu ; internals@lists.php.net Sent: Thursday, Ma

Re: [PHP-DEV] question about Zend MM

2012-03-01 Thread Gustavo Lopes
On Thu, 01 Mar 2012 17:22:23 +0100, Adi Mutu wrote: I want to understand how Zend MM works, so i'm looking trought the sources and i see this: #define ZEND_MM_ALIGNMENT_MASK ~(ZEND_MM_ALIGNMENT-1) #define ZEND_MM_ALIGNED_SIZE(size) (((size) + ZEND_MM_ALIGNMENT - 1) & ZEND_MM_ALIGNMENT_MA

[PHP-DEV] question about Zend MM

2012-03-01 Thread Adi Mutu
Hello, I want to understand how Zend MM works, so i'm looking trought the sources and i see this: #define ZEND_MM_ALIGNMENT_MASK ~(ZEND_MM_ALIGNMENT-1) #define ZEND_MM_ALIGNED_SIZE(size)(((size) + ZEND_MM_ALIGNMENT - 1) & ZEND_MM_ALIGNMENT_MASK) I understand that the first define

Re: [PHP-DEV] Scalar Type Intentions

2012-03-01 Thread Lazare Inepologlou
> > Of note, the scalar type hinting I've outlined does not automatically > perform casts... Thank you for your answer. Maybe, this exact fact is what I don't like about your suggestion. Please read the following RFC, where Lukas Smith and Zeev Suraski explain very well why strict type checking w

Re: [PHP-DEV] Scalar Type Intentions

2012-03-01 Thread Anthony Ferrara
Adam, Sure. Basically, if you alias the int hint to scalar: function foo(int $i) { } The following are all valid values for $i: $i = 1; $i = 1.5; $i = "1.9" $i = "foo" $i = true $i = fopen($file); So, in the future, if we wanted to implement loss-less casting (casting if possible without loosi

Re: [PHP-DEV] Scalar Type Intentions

2012-03-01 Thread Adam Jon Richardson
On Thu, Mar 1, 2012 at 8:55 AM, Anthony Ferrara wrote: > Please do not implement int, float, etc as an alias to scalar. That's > going to cause nothing but trouble later on. It will instantly close > the door to any type of casting magic (due to BC concerns), be > completely non-obvious ("I hin

Re: [PHP-DEV] Scalar Type Intentions

2012-03-01 Thread Adam Jon Richardson
On Thu, Mar 1, 2012 at 8:33 AM, Lazare Inepologlou wrote: > Yes, I agree, the casting (or the failing to cast) has to happen on entry, > for the reasons that you have very well explained. > > However, I cannot understand what it means to cast an object to a scalar. > Does it always mean casting to

Re: [PHP-DEV] Scalar Type Intentions

2012-03-01 Thread Anthony Ferrara
Please do not implement int, float, etc as an alias to scalar. That's going to cause nothing but trouble later on. It will instantly close the door to any type of casting magic (due to BC concerns), be completely non-obvious ("I hinted for int, why is it a boolean?"), and cause nothing but confus

Re: [PHP-DEV] Scalar Type Intentions

2012-03-01 Thread Lazare Inepologlou
Yes, I agree, the casting (or the failing to cast) has to happen on entry, for the reasons that you have very well explained. However, I cannot understand what it means to cast an object to a scalar. Does it always mean casting to string? Wouldn't that be slow in many cases? Simple example: clas

Re: [PHP-DEV] Scalar Type Intentions

2012-03-01 Thread Adam Jon Richardson
On Thu, Mar 1, 2012 at 4:36 AM, Lazare Inepologlou wrote: > And, *what if PHP added the following aliases for the hint scalar*: > > - bool > > - int > > - float > > - string >> > > If an object has a __toString method, does it qualify as a valid value to > be passed to a scalar argument? In my opi

Re: [PHP-DEV] Scalar type hinting

2012-03-01 Thread Kiall Mac Innes
On Thu, Mar 1, 2012 at 9:00 AM, Lester Caine wrote: > Both provide something that a large number of people did not or do not > want anything to do with. > I disagree - The majority of PHP developers I've discussed this with are in favor of adding *something *like this. Do a majority want this? I

Re: [PHP-DEV] PHP Philosophy (was RE: [PHP-DEV] Scalar type hinting)

2012-03-01 Thread jpauli
On Thu, Mar 1, 2012 at 9:52 AM, Simon Schick wrote: > Hi, John > > Just to add an idea to yours .. > > Do you think it's a compatibility-break if we'd decide to send a E_NOTICE > or E_WARNING if we f.e. try to give a string to a method that just allows > integer for this argument? > No break at al

Re: [PHP-DEV] [Draft RFC] Object Casting and Assignment Handlers

2012-03-01 Thread jpauli
On Thu, Mar 1, 2012 at 1:45 AM, Clint M Priest wrote: > As much as I would love to have __castTo() and __assign() I have to agree > with Stas here that it fundamentally changes the mechanics of if($object) > and unfortunately turns that simple if statement into a possible hour long > hunt to find

Re: [PHP-DEV] Newbie: issues developing a new extension

2012-03-01 Thread jpauli
On Wed, Feb 29, 2012 at 10:06 PM, Christian Ferrari wrote: > >> >> Dear all, > > >> > >> > > >> >>> > >> >> I'm asking your help because I'm not > > able to > >> > solve an > >> >> issue > >> probably > >> >related to some foolish mistake I have not yet > >

Re: [PHP-DEV] Vulnerability by loading doctype-declaration of xml

2012-03-01 Thread jpauli
Using DOM, this can be achieved with $domDocument->resolveExternals = false; before loading a document. Julien.P On Wed, Feb 29, 2012 at 9:52 PM, Gustavo Lopes wrote: > On Wed, 29 Feb 2012 19:30:15 +0100, Simon Schick < > simonsimc...@googlemail.com> wrote: > > I just read this post about a vul

Re: [PHP-DEV] Scalar Type Intentions

2012-03-01 Thread Pierre Joye
On Thu, Mar 1, 2012 at 10:39 AM, Sebastian Bergmann wrote: > On 03/01/2012 04:13 AM, Pierre Joye wrote: >> >> However, following your logic, class type hinting was a mistake? > > >  The Type Hinting we currently have for arrays, callables, classes, and >  interfaces is not a mistake. Why? Because

Re: [PHP-DEV] Scalar Type Intentions

2012-03-01 Thread Lester Caine
Pierre Joye wrote: On Thu, Mar 1, 2012 at 3:36 AM, Sebastian Bergmann wrote: usually does not work. > >2) What you want to achieve is already possible through docblocks. I am not saying that I like the idea of scalar type arguments, but you keep saying that docblocks solve such issue. Th

Re: [PHP-DEV] Scalar Type Intentions

2012-03-01 Thread Sebastian Bergmann
On 03/01/2012 04:13 AM, Pierre Joye wrote: However, following your logic, class type hinting was a mistake? The Type Hinting we currently have for arrays, callables, classes, and interfaces is not a mistake. Why? Because the types in question are not affected by the "type juggling". -- Seba

Re: [PHP-DEV] Scalar Type Intentions

2012-03-01 Thread Lazare Inepologlou
> > And, *what if PHP added the following aliases for the hint scalar*: - bool - int - float - string > If an object has a __toString method, does it qualify as a valid value to be passed to a scalar argument? In my opinion, it should. Your suggestion has a future compatibility problem. The i

Re: [PHP-DEV] Scalar Type Intentions

2012-03-01 Thread Pierre Joye
hi Sebastian, On Thu, Mar 1, 2012 at 3:36 AM, Sebastian Bergmann wrote:  usually does not work. > >  2) What you want to achieve is already possible through docblocks. I am not saying that I like the idea of scalar type arguments, but you keep saying that docblocks solve such issue. They are tot

Re: [PHP-DEV] PHP Philosophy (was RE: [PHP-DEV] Scalar type hinting)

2012-03-01 Thread Lazare Inepologlou
> That's what I was calling "inconsistent", specifically because (int)'foo' > == 0 with no warning whatsoever, but int $a = 'foo' would be 0 with an > error of some sort. Behavior with respect to when an error is raised is > inconsistent. In both cases there is a very lossy conversion, why is there

Re: [PHP-DEV] Scalar type hinting

2012-03-01 Thread Lester Caine
Kris Craig wrote: With all due respect, it's a logical fallacy to draw a direct comparison between these two simply because they both happen to be uphill battles. There is a direct comparison between the two. Both provide something that a large number of people did not or do not want anything

Re: [PHP-DEV] PHP Philosophy (was RE: [PHP-DEV] Scalar type hinting)

2012-03-01 Thread Pierre Joye
If any of you are interested in such change in PHP, please get together and write a complete RFC. As I do not see any kind of progress but, as you stated, some philosophical discussions. That's all good but after 2 weeks, it is time to move forward (or stop). Cheers, On Thu, Mar 1, 2012 at 4:02 A

RE: [PHP-DEV] PHP Philosophy (was RE: [PHP-DEV] Scalar type hinting)

2012-03-01 Thread John Crenshaw
From: Simon Schick [mailto:simonsimc...@googlemail.com] > > Hi, John > > Just to add an idea to yours .. > > Do you think it's a compatibility-break if we'd decide to send a E_NOTICE or > E_WARNING if we f.e. try to give a string to a method that just allows > integer for this argument? No break

Re: [PHP-DEV] Scalar Type Intentions

2012-03-01 Thread Alain Williams
On Wed, Feb 29, 2012 at 09:01:05PM -0500, Adam Jon Richardson wrote: > However, the lack of scalar hinting does limit the ability of a developer > to declare his/her intentions for function/method parameters. A non-hinted > parameter expecting a scalar could be sent an object or an array, breaking

Re: [PHP-DEV] PHP Philosophy (was RE: [PHP-DEV] Scalar type hinting)

2012-03-01 Thread Simon Schick
Hi, John Just to add an idea to yours .. Do you think it's a compatibility-break if we'd decide to send a E_NOTICE or E_WARNING if we f.e. try to give a string to a method that just allows integer for this argument? No break at all, just a E_NOTICE or E_WARNING as the script can succeed anyways.

Re: [PHP-DEV] Scalar Type Intentions

2012-03-01 Thread Simon Schick
Hi, Adam I just get the feeling that this is exactly what we're currently discovered in some other threads in this mailing-list. We're now getting more and more closer to what we really want and a good way to write it the PHP-way. Please try to get a rough overview over the last messages we wrote

RE: [PHP-DEV] PHP Philosophy (was RE: [PHP-DEV] Scalar type hinting)

2012-03-01 Thread John Crenshaw
> From: Richard Lynch [mailto:c...@l-i-e.com] > On Wed, February 29, 2012 7:16 pm, John Crenshaw wrote: > > I'm beginning to think that the type hinting question is too closely > > related to the dirty secrets of type juggling to resolve them > > separately. You may have to either discard consis

RE: [PHP-DEV] PHP Philosophy (was RE: [PHP-DEV] Scalar type hinting)

2012-03-01 Thread Arvids Godjuks
Secure code is not about the instrument, it's about how you write it. Insecure spagetti code can be written in any language.

RE: [PHP-DEV] PHP Philosophy (was RE: [PHP-DEV] Scalar type hinting)

2012-03-01 Thread John Crenshaw
> You might consider those scripts poor programming practice. We all do. > But PHP is the language of the unwashed masses, and that was, and is, > part of why it is hugely popular. Somebody who barely understands > programming can pound away at the keyboard and write a bloody useful > web applic