diff -u b/core/lib/Drupal/Core/Template/Attribute.php b/core/lib/Drupal/Core/Template/Attribute.php --- b/core/lib/Drupal/Core/Template/Attribute.php +++ b/core/lib/Drupal/Core/Template/Attribute.php @@ -333,7 +333,7 @@ * {@inheritdoc} */ public function count() { - return mb_strlen($this->__toString()); + return count($this->__toString()); } /** only in patch2: unchanged: --- a/core/lib/Drupal/Component/Render/FormattableMarkup.php +++ b/core/lib/Drupal/Component/Render/FormattableMarkup.php @@ -58,7 +58,7 @@ * @see \Drupal\Core\StringTranslation\PluralTranslatableMarkup * @see \Drupal\Component\Render\FormattableMarkup::placeholderFormat() */ -class FormattableMarkup implements MarkupInterface, \Countable { +class FormattableMarkup implements MarkupInterface { /** * The string containing placeholders. only in patch2: unchanged: --- a/core/lib/Drupal/Component/Render/HtmlEscapedText.php +++ b/core/lib/Drupal/Component/Render/HtmlEscapedText.php @@ -12,7 +12,7 @@ * * @ingroup sanitization */ -class HtmlEscapedText implements MarkupInterface, \Countable { +class HtmlEscapedText implements MarkupInterface { /** * The string to escape. only in patch2: unchanged: --- a/core/lib/Drupal/Core/Field/FieldFilteredMarkup.php +++ b/core/lib/Drupal/Core/Field/FieldFilteredMarkup.php @@ -19,7 +19,7 @@ * * @see \Drupal\Core\Render\Markup */ -final class FieldFilteredMarkup implements MarkupInterface, \Countable { +final class FieldFilteredMarkup implements MarkupInterface { use MarkupTrait; /** only in patch2: unchanged: --- a/core/lib/Drupal/Core/GeneratedLink.php +++ b/core/lib/Drupal/Core/GeneratedLink.php @@ -11,7 +11,7 @@ * Note: not to be confused with \Drupal\Core\Link, which is for passing around * ungenerated links (typically link text + route name + route parameters). */ -class GeneratedLink extends BubbleableMetadata implements MarkupInterface, \Countable { +class GeneratedLink extends BubbleableMetadata implements MarkupInterface { /** * HTML tag to use when building the link. only in patch2: unchanged: --- a/core/lib/Drupal/Core/Render/Markup.php +++ b/core/lib/Drupal/Core/Render/Markup.php @@ -19,7 +19,7 @@ * @see \Drupal\Core\Template\TwigExtension::escapeFilter * @see \Twig\Markup */ -final class Markup implements MarkupInterface, \Countable { +final class Markup implements MarkupInterface { use MarkupTrait; } only in patch2: unchanged: --- a/core/modules/big_pipe/src/Render/BigPipeMarkup.php +++ b/core/modules/big_pipe/src/Render/BigPipeMarkup.php @@ -18,7 +18,7 @@ * * @see \Drupal\Core\Render\Markup */ -final class BigPipeMarkup implements MarkupInterface, \Countable { +final class BigPipeMarkup implements MarkupInterface { use MarkupTrait; } only in patch2: unchanged: --- a/core/modules/filter/src/Render/FilteredMarkup.php +++ b/core/modules/filter/src/Render/FilteredMarkup.php @@ -19,7 +19,7 @@ * * @see \Drupal\Core\Render\Markup */ -final class FilteredMarkup implements MarkupInterface, \Countable { +final class FilteredMarkup implements MarkupInterface { use MarkupTrait; } only in patch2: unchanged: --- a/core/modules/migrate/src/Audit/AuditResult.php +++ b/core/modules/migrate/src/Audit/AuditResult.php @@ -8,7 +8,7 @@ /** * Encapsulates the result of a migration audit. */ -class AuditResult implements MarkupInterface, \Countable { +class AuditResult implements MarkupInterface { /** * The audited migration. only in patch2: unchanged: --- a/core/modules/views/src/Render/ViewsRenderPipelineMarkup.php +++ b/core/modules/views/src/Render/ViewsRenderPipelineMarkup.php @@ -18,7 +18,7 @@ * * @see \Drupal\Core\Render\Markup */ -final class ViewsRenderPipelineMarkup implements MarkupInterface, \Countable { +final class ViewsRenderPipelineMarkup implements MarkupInterface { use MarkupTrait; }