Hello, Khalil

Could you explain the pros of your proposal in comparison with the next one:

   <?php

   function somethingWillBeRemovedInNextVersion() {
         trigger_error('This function is deprecated. '
             . 'Please use "newFunction" instead. ',
         E_USER_DEPRECATED);


         // functionality below

         return 'something';
   }

   function newFunction() {
        // ...
   }

   somethingWillBeRemovedInNextVersion();


From my point of view, the modifier for this kind of things is the restriction for developers, who want to inform user about details like "why we are going to remove this functionality".

On 12/26/2012 04: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,
Yussuf Khalil


Reply via email to