Twig
Twig copied to clipboard
Inconsistent annotations and signatures in Node.php
https://github.com/twigphp/Twig/blob/3.x/src/Node/Node.php
Line 197 onwards, a few methods are said to accept either an int or a string, but the signature only accepts a string, there are a few methods like this.
I have an old symfony project that looks like it used to call hasNode() and getNode() with an int, I assume that it's the annotations that are deprecated and that there are no plans to keep the int in the signature?
Thank you for your time.
In fact, 4.0 will allow int (see #4223 for the preparation in 3.x and bca2d993b04686d49535e3fda9fc43071b4a07f3 for the type update in 4.x).