Make Markup final

This commit is contained in:
Fabien Potencier
2026-09-25 23:51:14 +02:00
parent 40b0349558
commit dbfd06ffba
2 changed files with 2 additions and 1 deletions
+1
View File
@@ -6,6 +6,7 @@
* Remove the now inert `#[YieldReady]` attribute from the built-in nodes; the attribute itself is kept so 3.x extensions still load
* Add an optional `string $template = ''` argument to `IncludeNode::addGetTemplate()`; subclasses overriding this method must declare a compatible parameter
* Remove the obsolete `Twig\Test\NodeTestCase::getTests()` method; override `provideTests()` instead
* Make `Twig\Markup` final
* Add native return types to the protected extension points in `Twig\Test\IntegrationTestCase` and `Twig\Test\NodeTestCase` and require overriding methods to declare compatible return types
* Remove `TemplateVariable` and `AssignTemplateVariable`; use `MacroVariable` and `AssignMacroVariable` instead
* Add the `isAlwaysAllowedInSandbox()` method to `Twig\TwigCallableInterface` and `Twig\TokenParser\TokenParserInterface`
+1 -1
View File
@@ -22,7 +22,7 @@ namespace Twig;
*
* @author Fabien Potencier <fabien@symfony.com>
*/
class Markup implements \Countable, \JsonSerializable, \Stringable
final class Markup implements \Countable, \JsonSerializable, \Stringable
{
private string $content;
private ?string $charset;