Merge branch '3.x' into 4.x

* 3.x:
  use getShareDir as an indicator of Symfony version
  Add 'invoke' to filters index
  [Core] Fix cycle() with non-countable ArrayAccess+Traversable objects
  Update .gitattributes to exclude phpstan configs
  Bump version
  Prepare the 3.22.1 release
  Update CHANGELOG
  `CoreExtension` : Make error message more readable
  Add caution note for random function usage
  Add throw tag to parse methods
This commit is contained in:
Fabien Potencier
2025-12-05 09:58:08 +01:00
9 changed files with 27 additions and 5 deletions
+5
View File
@@ -86,6 +86,9 @@ class Parser
return $this->env;
}
/**
* @throws SyntaxError
*/
public function parse(TokenStream $stream, $test = null, bool $dropNeedle = false): ModuleNode
{
$vars = get_object_vars($this);
@@ -170,6 +173,8 @@ class Parser
/**
* @phpstan-impure
*
* @throws SyntaxError
*/
public function subparse($test, bool $dropNeedle = false): Node
{