Skip to content

twigphp/Twig

3.x
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

This PR was merged into the 3.x branch.

Discussion
----------

Remove internal from ExpressionParser

In the advanced doc, it's explained how to write TokenParser:
https://github.com/twigphp/Twig/blob/3.x/doc/advanced.rst#defining-a-token-parser

Such an implementation rely on method like
ExpressionParser::parseExpression or Expression::parseMultitargetExpression,

Currently the ExpressionParser is marked as internal, implying all the method are also internal.
It would be great to promise BC about those methods since they are require/usefull for custom TokenParser.

I dunno if the ``@internal`` tag is still needed for some methods of the ExpressionParser (like the constructor ?).

This would also
Closes #3443

Commits
-------

de0f947 Remove internal from ExpressionParser
ce55cb8

Git stats

Files

Permalink
Failed to load latest commit information.

Twig, the flexible, fast, and secure template language for PHP

Twig is a template language for PHP.

Twig uses a syntax similar to the Django and Jinja template languages which inspired the Twig runtime environment.

Sponsors

Blackfire.io

More Information

Read the documentation for more information.