diff --git a/core/lib/Drupal/Component/Render/FormattableMarkup.php b/core/lib/Drupal/Component/Render/FormattableMarkup.php
index 26fbc0b47c609d9482e08130febdebebfc6d1d45..44e8171080ae81a0d44b0a56bf404494aab09e52 100644
--- a/core/lib/Drupal/Component/Render/FormattableMarkup.php
+++ b/core/lib/Drupal/Component/Render/FormattableMarkup.php
@@ -113,11 +113,11 @@ public function jsonSerialize(): string {
    * // Wraps $some_variable in an <em> tag.
    * $this->placeholderFormat('Prefix %foo', ['%foo' => $some_variable]);
    * // The following are using the : placeholder inside an HTML tag.
-   * $this->placeholderFormat('<a href=":foo">link text</a>, ['@foo' => $some_variable]);
-   * $this->placeholderFormat('<a href=":foo" title="static text">link text</a>, ['@foo' => $some_variable]);
-   * $this->placeholderFormat('<a href=":foo">@foo</a>, ['@foo' => $some_variable]);
+   * $this->placeholderFormat('<a href=":foo">link text</a>', [':foo' => $some_variable]);
+   * $this->placeholderFormat('<a href=":foo" title="static text">link text</a>', [':foo' => $some_variable]);
+   * $this->placeholderFormat('<a href=":foo">link text</a>', [':foo' => $some_variable]);
    * // Use : placeholder inside an HTML tag.
-   * $this->placeholderFormat('<img src=":foo" />, ['@foo' => '/image.png']);
+   * $this->placeholderFormat('<img src=":foo" />', [':foo' => '/image.png']);
    * @endcode
    * The above are typical examples of using the placeholders correctly.
    *