diff --git a/core/lib/Drupal/Core/Render/Element/Table.php b/core/lib/Drupal/Core/Render/Element/Table.php
index c13b623..4cd571e 100644
--- a/core/lib/Drupal/Core/Render/Element/Table.php
+++ b/core/lib/Drupal/Core/Render/Element/Table.php
@@ -200,7 +200,7 @@ public static function processTable(&$element, FormStateInterface $form_state, &
               }
             }
             if (isset($title) && $title !== '') {
-              $title = t('Update !title', array('!title' => $title));
+              $title = t('Update @title', array('@title' => $title));
             }
           }
 
diff --git a/core/modules/system/src/Tests/Theme/TableTest.php b/core/modules/system/src/Tests/Theme/TableTest.php
index e65037c..de61c57 100644
--- a/core/modules/system/src/Tests/Theme/TableTest.php
+++ b/core/modules/system/src/Tests/Theme/TableTest.php
@@ -21,7 +21,7 @@ class TableTest extends KernelTestBase {
    *
    * @var array
    */
-  public static $modules = array('system');
+  public static $modules = ['system', 'form_test'];
 
   /**
    * {@inheritdoc}
@@ -308,4 +308,15 @@ public function testThemeTableRowRenderArray() {
     $this->assertRaw('<tbody><tr><td>1-one</td><td>1-two</td><td>1-three</td></tr>', 'Table row 1 found.');
     $this->assertRaw('<tr><td>2-one</td><td>2-two</td><td><b>2-three</b></td></tr></tbody>', 'Table row 2 found.');
   }
+
+  /**
+   * Tests that the select/checkbox label is being generated and escaped.
+   */
+  public function testThemeTableTitle() {
+    $form = \Drupal::formBuilder()->getForm('\Drupal\form_test\Form\FormTestTableForm');
+    $this->render($form);
+    $this->assertEscaped('Update <em>kitten</em>');
+    $this->assertRaw('Update my favourite fruit is <strong>bananas</strong>');
+  }
+
 }
diff --git a/core/modules/system/tests/modules/form_test/src/Form/FormTestTableForm.php b/core/modules/system/tests/modules/form_test/src/Form/FormTestTableForm.php
new file mode 100644
index 0000000..c7fc112
--- /dev/null
+++ b/core/modules/system/tests/modules/form_test/src/Form/FormTestTableForm.php
@@ -0,0 +1,53 @@
+<?php
+
+/**
+ * @file
+ * Contains \Drupal\form_test\Form\FormTestTableForm.
+ */
+
+namespace Drupal\form_test\Form;
+
+use Drupal\Core\Form\FormStateInterface;
+use Drupal\Core\Render\SafeString;
+
+class FormTestTableForm extends FormTestTableSelectFormBase {
+
+  /**
+   * {@inheritdoc}
+   */
+  public function getFormId() {
+    return '_form_test_table_form';
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public function buildForm(array $form, FormStateInterface $form_state) {
+    $form['table'] = [
+      '#type' => 'table',
+      '#tableselect' => TRUE,
+      '#empty' => t('Empty text.'),
+    ];
+    $form['table']['row'] = [
+      'data' => [
+        '#title' => '<em>kitten</em>',
+        '#markup' => '<p>some text</p>',
+      ],
+    ];
+    $form['table']['another_row'] = [
+      'data' => [
+        '#title' => $this->t('my favourite fruit is <strong>@fruit</strong>', ['@fruit' => 'bananas']),
+        '#markup' => '<p>some more text</p>',
+      ],
+    ];
+
+    return $form;
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public function submitForm(array &$form, FormStateInterface $form_state) {
+  }
+
+}
