Re: $http_response_header

From: Date: Fri, 27 Mar 2015 18:12:45 +0000
Subject: Re: $http_response_header
References: 1 2 3 4 5 6 7 8 9  Groups: php.internals 
Request: Send a blank email to internals+get-85512@lists.php.net to get a copy of this message
Ferenc Kovacs wrote on 27/03/2015 16:50:
yeah, but we already mentioned/discussed this that the removal would require introducing another way (eg. adding a method) for fetching the headers. I think that introducing this method can happen in a minor version(without removing the $http_response_header variable), so I will create a pull request and ask Julien about including it in 5.5 and upwards.
I've seen comments to this effect before, and don't really understand the motivation for adding functions in patch versions. Personally, I'd never rely on such a function, because it would mean my code relied on a version spec like "(>= 5.5.23 && < 5.6.0) || >= 5.6.7", which is just horrible. And on the negative side, there's the (admittedly very small) possibility of unexpectedly colliding with someone's existing function. The definition at SemVer.org (I know PHP doesn't officially follow this definition, but it's a well-thought out point of reference) makes clear:
Minor version Y (x.Y.z | x > 0) MUST be incremented if new, backwards compatible functionality is introduced to the public API.
Isn't it enough if the new function, and the deprecation of the variable, is snuck into 7.0, or added in 7.1? Regards, -- Rowan Collins [IMSoP]

« previous php.internals (#85512) next »