Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-80118

PHP 8.4: Deprecate functions with overloaded signatures

XMLWordPrintable

    • MOODLE_403_STABLE, MOODLE_404_STABLE
    • Hide
      1. DatePeriod

        ag 'DatePeriod'
        

        1. Confirm not used at all
      2. dba_fetch

        ag 'dba_fetch'
        

        1. Confirm not used at all
      3. FFI::cast(), FFI::new(), FFI::type()

        ag 'FFI::'
        

        1. Confirm not used at all
          not in use in core
      4. IntlCalendar::set()

        ag 'IntlCalendar'
        

        1. Confirm not used at all
      5. IntlGregorianCalendar::__construct()

        ag 'IntlGregorianCalendar'
        

        1. Confirm this is not in the form new IntlGregorianCalendar
      6. ldap_connect

        ag '(?<!>)ldap_connect\('
        

        1. Check that there are no calls to ldap_connect with 3 or more args
      7. ldap_exop

        ag 'ldap_exop'
        

        1. Confirm not used at all
      8. pg_fetch_result, pg_field_prtlen, pg_field_is_null

        ag 'pg_fetch_result|pg_field_prtlen|pg_field_is_null'
        

        1. Confirm not used at all
      9. Phar::setStub()

        ag 'Phar::setStub'
        

        1. Confirm not used at all
      10. session_set_save_handler with six arguments

        ag 'session_set_save_handler\('
        

        1. Confirm all uses have fewer than six args
      11. stream_context_set_option with only two args

        ag 'stream_context_set_option\('
        

        1. Confirm not used at all
      12. ReflectionMethod::__construct() with only one arg

        ag 'new *ReflectionMethod\([^,]*\)'
        

        1. Confirm no uses found
      Show
      DatePeriod ag 'DatePeriod' Confirm not used at all dba_fetch ag 'dba_fetch' Confirm not used at all FFI::cast(), FFI::new(), FFI::type() ag 'FFI::' Confirm not used at all not in use in core IntlCalendar::set() ag 'IntlCalendar' Confirm not used at all IntlGregorianCalendar::__construct() ag 'IntlGregorianCalendar' Confirm this is not in the form new IntlGregorianCalendar ldap_connect ag '(?<!>)ldap_connect\(' Check that there are no calls to ldap_connect with 3 or more args ldap_exop ag 'ldap_exop' Confirm not used at all pg_fetch_result , pg_field_prtlen , pg_field_is_null ag 'pg_fetch_result|pg_field_prtlen|pg_field_is_null' Confirm not used at all Phar::setStub() ag 'Phar::setStub' Confirm not used at all session_set_save_handler with six arguments ag 'session_set_save_handler\(' Confirm all uses have fewer than six args stream_context_set_option with only two args ag 'stream_context_set_option\(' Confirm not used at all ReflectionMethod::__construct() with only one arg ag 'new *ReflectionMethod\([^,]*\)' Confirm no uses found

      This is probably the biggest barrier for PHP 8.3 support. I believe only one other issue actually requires any changes.

      https://php.watch/rfcs/deprecate_functions_with_overloaded_signatures
      https://wiki.php.net/rfc/deprecate_functions_with_overloaded_signatures

      Methods to look for:

      1. array_keys with more than one argument
        • *NOT DEPRECATED*
      2. DatePeriod::__construct() with various constructors
        • not in use in core
      3. dba_fetch
        • not in use in core
      4. FFI::cast(), FFI::new(), FFI::type()
        • not in use in core
      5. IntlCalendar::set()
        • not in use in core
      6. IntlGregorianCalendar::__construct()
        • not in use in core
      7. ldap_connect
        • deprecated call not used
      8. ldap_exop
        • not in use in core
      9. pg_fetch_result, pg_field_prtlen, pg_field_is_null
        • not in use in core
      10. Phar::setStub
        • not in use in core
      11. session_set_save_handler with six arguments
        • We always use the standard two-argument call to it but should confirm
      12. stream_context_set_option with only two args
        • not in use in core
      13. ReflectionMethod::__construct() with only one arg
        • not in use in core

          ag 'new *ReflectionMethod\([^,]*\)'
          

      This issue requires going through each of the deprecations in the RFC to confirm that all are addressed.
      Please use one commit per RFC change where relevant
      Please comment to confirm my findings where they are not used.

            dobedobedoh Andrew Lyons
            dobedobedoh Andrew Lyons
            Stevani Andolo Stevani Andolo
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 17 minutes
                17m

                  Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.