# Yet Another Stupid Question: Why Bother with Compatibility?

- Thread: https://externals.io/message/15974
- Original archive: https://news-web.php.net/php.internals/15974
- Started by GamblerZG on 2005-04-15T17:03:44+00:00
- Messages: 3
- Reply by email to internals@lists.php.net
- More for agents: search with https://externals.io/search.md?q={query} · JSON API at https://externals.io/api · documentation at https://externals.io/llms.txt

---

## #15974 — GamblerZG — 2005-04-15T17:03:44+00:00

URL: https://externals.io/message/15974#15974

Maintaining compatibility between different major versions of PHP must 
be extremely hard. Maybe that is obvious, but I do not quite understand 
why developers do it. Why PHP 5 has to understand deprecated syntax of 
PHP 4? I mean, if someone needs to execute old scripts, they can always 
use old engine.

---

## #15976 — Paul Reinheimer — 2005-04-15T17:49:15+00:00

URL: https://externals.io/message/15974#15976 · In reply to: #15974

The advantage of maintaining reverse compatibility is that it helps encourage
people to upgrade. Many more people would have many more concerns if the
4 -> 5 upgrade broke programs using depreciated practices. ISPs and hosting
companies in particular would be extremely reluctant to upgrade as it would
promptly result in several (hundred?) support tickets asking "My code worked
yesterday, now it doesn't! What did you do?!!!!!?!!".

I will be honest, I've written the majority of my code in the last
year, but am I
100% positive that I'm not using anything that was marked as depreciated in
PHP 4? Absolutely not. For all I know I might be using some deprecated function
in some arcane, rarely used administrative include file hiding somewhere in the
depths of my file system. Everything would apparently keep working when I
upgraded, and even for days/weeks after the fact. Then boom, one day something
important brakes, and I have no idea why.


I would assume that the percentage of people willing to upgrade is directly
proportional to the percentage of BC.


just my 2cents (canadian).


paul



> Maintaining compatibility between different major versions of PHP must
> be extremely hard. Maybe that is obvious, but I do not quite understand
> why developers do it. Why PHP 5 has to understand deprecated syntax of
> PHP 4? I mean, if someone needs to execute old scripts, they can always
> use old engine.
> 
> --
> 
> 
> 
> 


-- 
Paul Reinheimer
Zend Certified Engineer

---

## #15977 — GamblerZG — 2005-04-15T19:07:53+00:00

URL: https://externals.io/message/15974#15977 · In reply to: #15976

Paul Reinheimer wrote:
 > The advantage of maintaining reverse compatibility is that it helps 
encourage
 > people to upgrade. Many more people would have many more concerns if the
 > 4 -> 5 upgrade broke programs using depreciated practices.

Well, that's the thing I don't get. If I have working system for PHP 4 
engine, why would I want to _upgrade_ (i.e. switch) to PHP 5 engine? 
Would it not be more compelling for me to have 4 and 5 as separate 
Apache modules or something like that? Interoperability problem could be 
solved by some kind of inter-version bridge (like PHP/Java integration 
module). A the same time, this would free PHP developers from BC.

 > I will be honest, I've written the majority of my code in the last
 > year, but am I
 > 100% positive that I'm not using anything that was marked as 
depreciated in
 > PHP 4? Absolutely not. For all I know I might be using some 
deprecated function
 > in some arcane, rarely used administrative include file hiding 
somewhere in the
 > depths of my file system. Everything would apparently keep working when I
 > upgraded, and even for days/weeks after the fact. Then boom, one day 
something
 > important brakes, and I have no idea why.

Look at your situation from different perspective. Wouldn't it be nice 
to be absolutely sure that your website does not uses any deprecated 
code? You would most certainly know that if PHP 3 and PHP 4 would be 
handled by different engines.
