Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:95373 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 92324 invoked from network); 22 Aug 2016 14:00:41 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 22 Aug 2016 14:00:41 -0000 Authentication-Results: pb1.pair.com header.from=morrison.levi@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=morrison.levi@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.220.42 as permitted sender) X-PHP-List-Original-Sender: morrison.levi@gmail.com X-Host-Fingerprint: 209.85.220.42 mail-pa0-f42.google.com Received: from [209.85.220.42] ([209.85.220.42:33968] helo=mail-pa0-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 72/E7-35246-7850BB75 for ; Mon, 22 Aug 2016 10:00:39 -0400 Received: by mail-pa0-f42.google.com with SMTP id fi15so38069919pac.1 for ; Mon, 22 Aug 2016 07:00:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=2DNk7BqDauVfYbaTm5brC8lRH5yuyVoDImboMwetw8s=; b=lCVb4Qv2sS/8YdgkZX7GSx38vt43rXAyLu/lDP1hpIjAPAmUBYwtjAAyKGUo+F+BaK igMbjhbNxSDQzLfniSM1R9XBxLHdwBXc0n2SpAvchS2JJ/F2dwURpBazd4BYMaW2uLSN tNyJtwbAklDFkp5lMM2ySCuSlaaDlW6lI+rBVQA/DEnynHZPQV0z5IouYyoyIqYkUueI ppq001MYRXwsha7MXyg00NRVbUtqaxK7yNPgzkVncG3i/JMTsU5Hmk/q+fyPEKH9/Y2L nsnAOM81LjtD34IdnyDSu8M082OEcJx46kpFYOk+GDL+cBONFJTxRY8nXBq4aICDTctU Ipdg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=2DNk7BqDauVfYbaTm5brC8lRH5yuyVoDImboMwetw8s=; b=Y+jWauJumcpN1pO09NG8MRcOLNr8JagUMUuIeEp+QkwMNigZ4Xz5sE+5+0d4AqAiPW 6VXOLp/KEfRuKwJShzq8S2BPokLd0SaweJ4TQBTORvrBhoXXa7Jqsmp1cgSccJFuJxZq mXdmTd9PHNpxJIORyLAKUDeWmmEeLZRnxWc8AHq8h147TZ0QSDSMXr/AEVLjSX0hlB7l seVIXMCp64E/Hg9tibCQDaGqg46sWs5Pe2KId1Yh4TM3ap7DPBhzBbE8OvS1RNIjnRBU LHjL1HTfllEoerV7Oj3Q0CMipTBm0PQNIFSpAjUjw5IShXqLZWS+dQsCf9kVHRYlFfwq jUEA== X-Gm-Message-State: AEkoousYPNq61Fu3tyF/o/HyX/J2FU6EyFGvFr9gMZsii8B+B3LimA8GVJvrxvAYlNpnb/+VBg9QF15UT34eIA== X-Received: by 10.66.43.7 with SMTP id s7mr43334972pal.27.1471874436699; Mon, 22 Aug 2016 07:00:36 -0700 (PDT) MIME-Version: 1.0 Sender: morrison.levi@gmail.com Received: by 10.66.24.42 with HTTP; Mon, 22 Aug 2016 07:00:36 -0700 (PDT) In-Reply-To: References: Date: Mon, 22 Aug 2016 08:00:36 -0600 X-Google-Sender-Auth: S6m5mUSvJ-TUlP9TXiJPbJbXRH4 Message-ID: To: Nicolas Grekas Cc: "internals@lists.php.net" Content-Type: multipart/alternative; boundary=bcaec5304bc7f42490053aa97845 Subject: Re: [PHP-DEV] BC break: ReflectionMethod::invoke() expects parameter 1 to be object, string given From: levim@php.net (Levi Morrison) --bcaec5304bc7f42490053aa97845 Content-Type: text/plain; charset=UTF-8 On Mon, Aug 22, 2016 at 5:17 AM, Nicolas Grekas < nicolas.grekas+php@gmail.com> wrote: > Hello, > > now that the BC break on ReflectionType has been reverted, another one > remains in ReflectionMethod::invoke(): > > the method doesn't accept a string as first argument anymore, see e.g.: > > https://3v4l.org/pImmv > > As you can see, this worked since 5.0 and even in HHVM. > > It would be great to fix this BC break please. > > Regards, > Nicolas > According to the [documentation][1] it requires an object. If the documentation has not been altered recently to make it this way then I'm inclined to keep the backward compatibility break. Your example uses a static method - you should be passing null and not the name of the class (this is also in the documentation). [1]: http://php.net/manual/en/reflectionmethod.invoke.php --bcaec5304bc7f42490053aa97845--