diff --git a/core/includes/bootstrap.inc b/core/includes/bootstrap.inc
index faecf9b9a4519f098fc54232556298e7668d4e2f..ae3f55ac27c151bd6d69effdf355d679c5978d8f 100644
--- a/core/includes/bootstrap.inc
+++ b/core/includes/bootstrap.inc
@@ -695,7 +695,7 @@ function watchdog_exception($type, Exception $exception, $message = NULL, $varia
  *   If there are no messages set, the function returns NULL.
  *
  * @see drupal_get_messages()
- * @see theme_status_messages()
+ * @see status-messages.html.twig
  */
 function drupal_set_message($message = NULL, $type = 'status', $repeat = FALSE) {
   if (isset($message)) {
@@ -742,7 +742,7 @@ function drupal_set_message($message = NULL, $type = 'status', $repeat = FALSE)
  *   drupal_set_message() for the array structure of individual messages.
  *
  * @see drupal_set_message()
- * @see theme_status_messages()
+ * @see status-messages.html.twig
  */
 function drupal_get_messages($type = NULL, $clear_queue = TRUE) {
   if ($messages = drupal_set_message()) {
diff --git a/core/includes/common.inc b/core/includes/common.inc
index 3ec95769e5500cb2d42c0ba5c7b4f0905a6fbee7..d05ee0c537f05da16dd45fa6dbc1d6bee8079f15 100644
--- a/core/includes/common.inc
+++ b/core/includes/common.inc
@@ -1968,8 +1968,8 @@ function _drupal_add_library($library_name, $every_page = NULL) {
  *
  * To set up a table to use drag and drop in place of weight select-lists or in
  * place of a form that contains parent relationships, the form must be themed
- * into a table. The table must have an ID attribute set. If using
- * theme_table(), the ID may be set as follows:
+ * into a table. The table must have an ID attribute set and it
+ * may be set as follows:
  * @code
  * $table = array(
  *   '#type' => 'table',
diff --git a/core/includes/form.inc b/core/includes/form.inc
index 52f2a1ed70f74754ac64499492d37ba14f65c970..69c970f39f04a9e4630d84cc5c569491152a5da2 100644
--- a/core/includes/form.inc
+++ b/core/includes/form.inc
@@ -476,7 +476,7 @@ function template_preprocess_form_element(&$variables) {
  *
  * Form element labels include the #title and a #required marker. The label is
  * associated with the element itself by the element #id. Labels may appear
- * before or after elements, depending on theme_form_element() and
+ * before or after elements, depending on form-element.html.twig and
  * #title_display.
  *
  * This function will not be called for elements with no labels, depending on
diff --git a/core/includes/theme.inc b/core/includes/theme.inc
index 7bbd4ff90c9b1dca6276ec17c54abdc4ce063fc5..102872be1f09fc9d4e0727565d7ea612dd09e2ea 100644
--- a/core/includes/theme.inc
+++ b/core/includes/theme.inc
@@ -1095,9 +1095,9 @@ function template_preprocess_item_list(&$variables) {
         // If this child element does not specify how it can be rendered, then
         // we need to inherit the render properties of the current list.
         if (!isset($child['#type']) && !isset($child['#theme']) && !isset($child['#markup'])) {
-          // Since theme_item_list() supports both strings and render arrays as
-          // items, the items of the nested list may have been specified as the
-          // child elements of the nested list, instead of #items. For
+          // Since item-list.html.twig supports both strings and render arrays
+          // as items, the items of the nested list may have been specified as
+          // the child elements of the nested list, instead of #items. For
           // convenience, we automatically move them into #items.
           if (!isset($child['#items'])) {
             // This is the same condition as in
@@ -1553,7 +1553,7 @@ function theme_get_suggestions($args, $base, $delimiter = '__') {
 }
 
 /**
- * Prepare variables for maintenance page templates.
+ * Prepares variables for maintenance page templates.
  *
  * Default template: maintenance-page.html.twig.
  *
diff --git a/core/lib/Drupal/Core/Database/Query/TableSortExtender.php b/core/lib/Drupal/Core/Database/Query/TableSortExtender.php
index 4786f5973c56f278e85d390f0b61af8c6a5b15cf..56cfc2c625131595216f1f99333ae82a1de31985 100644
--- a/core/lib/Drupal/Core/Database/Query/TableSortExtender.php
+++ b/core/lib/Drupal/Core/Database/Query/TableSortExtender.php
@@ -37,7 +37,7 @@ public function __construct(SelectInterface $query, Connection $connection) {
    * @return \Drupal\Core\Database\Query\SelectInterface
    *   The called object.
    *
-   * @see theme_table()
+   * @see table.html.twig
    */
   public function orderByHeader(array $header) {
     $this->header = $header;
diff --git a/core/lib/Drupal/Core/Entity/EntityListBuilder.php b/core/lib/Drupal/Core/Entity/EntityListBuilder.php
index 9e41b08337330e6f62f954303bf0a20553e6d8bb..aac37634de693421c6de80a7e917f0995b44579f 100644
--- a/core/lib/Drupal/Core/Entity/EntityListBuilder.php
+++ b/core/lib/Drupal/Core/Entity/EntityListBuilder.php
@@ -184,7 +184,7 @@ public function buildOperations(EntityInterface $entity) {
   /**
    * {@inheritdoc}
    *
-   * Builds the entity listing as renderable array for theme_table().
+   * Builds the entity listing as renderable array for table.html.twig.
    *
    * @todo Add a link to add a new item to the #empty text.
    */
diff --git a/core/lib/Drupal/Core/Entity/Query/QueryInterface.php b/core/lib/Drupal/Core/Entity/Query/QueryInterface.php
index 5a34cacff1ce31fa5b2d95bb5c71555056ab3cbe..caadc37f6edda09f21185e21b307fb686dd94565 100644
--- a/core/lib/Drupal/Core/Entity/Query/QueryInterface.php
+++ b/core/lib/Drupal/Core/Entity/Query/QueryInterface.php
@@ -149,9 +149,11 @@ public function count();
    * Enables sortable tables for this query.
    *
    * @param $headers
-   *   An array of headers of the same structure as described in theme_table().
-   *   Use a 'specifier' in place of a 'field' to specify what to sort on.
-   *   This can be an entity or a field as described in condition().
+   *   An array of headers of the same structure as described in
+   *   template_preprocess_table(). Use a 'specifier' in place of a 'field' to
+   *   specify what to sort on. This can be an entity or a field as described
+   *   in condition().
+   *
    * @return \Drupal\Core\Entity\Query\QueryInterface
    *   The called object.
    */
diff --git a/core/lib/Drupal/Core/Form/FormBuilder.php b/core/lib/Drupal/Core/Form/FormBuilder.php
index bf356001d6c8abbd23843b9a0606b76c9def09ae..108d5a16927664a29bd1ee004679306fe88e3ac2 100644
--- a/core/lib/Drupal/Core/Form/FormBuilder.php
+++ b/core/lib/Drupal/Core/Form/FormBuilder.php
@@ -613,9 +613,9 @@ public function prepareForm($form_id, &$form, FormStateInterface &$form_state) {
 
     $build_info = $form_state->getBuildInfo();
     // If no #theme has been set, automatically apply theme suggestions.
-    // theme_form() itself is in #theme_wrappers and not #theme. Therefore, the
-    // #theme function only has to care for rendering the inner form elements,
-    // not the form itself.
+    // The form theme hook itself, which is rendered by form.html.twig,
+    // is in #theme_wrappers. Therefore, the #theme function only has to care
+    // for rendering the inner form elements, not the form itself.
     if (!isset($form['#theme'])) {
       $form['#theme'] = array($form_id);
       if (isset($build_info['base_form_id'])) {
diff --git a/core/lib/Drupal/Core/Render/Element/Actions.php b/core/lib/Drupal/Core/Render/Element/Actions.php
index 1aab7d1e16e5d16846f3744f9d72889b3b2bdc10..eed3d11b3d57aa230502b103e1b834a7efa67219 100644
--- a/core/lib/Drupal/Core/Render/Element/Actions.php
+++ b/core/lib/Drupal/Core/Render/Element/Actions.php
@@ -92,7 +92,7 @@ public static function preRenderActionsDropbutton(&$element, FormStateInterface
           );
         }
         // Add this button to the corresponding dropbutton.
-        // @todo Change #type 'dropbutton' to be based on theme_item_list()
+        // @todo Change #type 'dropbutton' to be based on item-list.html.twig
         //   instead of links.html.twig to avoid this preemptive rendering.
         $button = drupal_render($element[$key]);
         $dropbuttons[$dropbutton]['#links'][$key] = array(
diff --git a/core/lib/Drupal/Core/Render/Element/Button.php b/core/lib/Drupal/Core/Render/Element/Button.php
index 11a9093a48f524505ad81be186a49efb72e73878..c305e229b1654ae52ee9b77b4a0d33c56c619c48 100644
--- a/core/lib/Drupal/Core/Render/Element/Button.php
+++ b/core/lib/Drupal/Core/Render/Element/Button.php
@@ -56,7 +56,7 @@ public static function processButton(&$element, FormStateInterface $form_state,
   }
 
   /**
-   * Prepares a #type 'button' render element for theme_input().
+   * Prepares a #type 'button' render element for input.html.twig.
    *
    * @param array $element
    *   An associative array containing the properties of the element.
@@ -66,7 +66,7 @@ public static function processButton(&$element, FormStateInterface $form_state,
    * styles the following button_types appropriately: 'primary', 'danger'.
    *
    * @return array
-   *   The $element with prepared variables ready for theme_input().
+   *   The $element with prepared variables ready for input.html.twig.
    */
   public static function preRenderButton($element) {
     $element['#attributes']['type'] = 'submit';
diff --git a/core/lib/Drupal/Core/Render/Element/Checkbox.php b/core/lib/Drupal/Core/Render/Element/Checkbox.php
index 6a99ecae9e1f27bd14a2195a9b785e559ac179bb..6574685999a02872b2ab6c5ead8e953e9169f42d 100644
--- a/core/lib/Drupal/Core/Render/Element/Checkbox.php
+++ b/core/lib/Drupal/Core/Render/Element/Checkbox.php
@@ -75,7 +75,7 @@ public static function valueCallback(&$element, $input, FormStateInterface $form
   }
 
   /**
-   * Prepares a #type 'checkbox' render element for theme_input().
+   * Prepares a #type 'checkbox' render element for input.html.twig.
    *
    * @param array $element
    *   An associative array containing the properties of the element.
@@ -83,7 +83,7 @@ public static function valueCallback(&$element, $input, FormStateInterface $form
    *   #attributes, #checked.
    *
    * @return array
-   *   The $element with prepared variables ready for theme_input().
+   *   The $element with prepared variables ready for input.html.twig.
    */
   public static function preRenderCheckbox($element) {
     $element['#attributes']['type'] = 'checkbox';
diff --git a/core/lib/Drupal/Core/Render/Element/Color.php b/core/lib/Drupal/Core/Render/Element/Color.php
index fa057998427a2e2a697191eb4e553da0136d8211..5f33bb6a42422d5d8814b5931af1076152aa8650 100644
--- a/core/lib/Drupal/Core/Render/Element/Color.php
+++ b/core/lib/Drupal/Core/Render/Element/Color.php
@@ -62,14 +62,14 @@ public static function validateColor(&$element, FormStateInterface $form_state,
   }
 
   /**
-   * Prepares a #type 'color' render element for theme_input().
+   * Prepares a #type 'color' render element for input.html.twig.
    *
    * @param array $element
    *   An associative array containing the properties of the element.
    *   Properties used: #title, #value, #description, #attributes.
    *
    * @return array
-   *   The $element with prepared variables ready for theme_input().
+   *   The $element with prepared variables ready for input.html.twig.
    */
   public static function preRenderColor($element) {
     $element['#attributes']['type'] = 'color';
diff --git a/core/lib/Drupal/Core/Render/Element/Email.php b/core/lib/Drupal/Core/Render/Element/Email.php
index c17633f3146340e1bb156498798bdbd4382bb676..25e88c32b3f81b4db413c2a3e772cdd03dd3f74c 100644
--- a/core/lib/Drupal/Core/Render/Element/Email.php
+++ b/core/lib/Drupal/Core/Render/Element/Email.php
@@ -70,7 +70,7 @@ public static function validateEmail(&$element, FormStateInterface $form_state,
   }
 
   /**
-   * Prepares a #type 'email' render element for theme_input().
+   * Prepares a #type 'email' render element for input.html.twig.
    *
    * @param array $element
    *   An associative array containing the properties of the element.
@@ -78,7 +78,7 @@ public static function validateEmail(&$element, FormStateInterface $form_state,
    *   #placeholder, #required, #attributes.
    *
    * @return array
-   *   The $element with prepared variables ready for theme_input().
+   *   The $element with prepared variables ready for input.html.twig.
    */
   public static function preRenderEmail($element) {
     $element['#attributes']['type'] = 'email';
diff --git a/core/lib/Drupal/Core/Render/Element/File.php b/core/lib/Drupal/Core/Render/Element/File.php
index 848e401a0ec353a00ce88692852d2d7ebe52d8e1..5f72c8d38a11e023c7a39a8ab3033ab59c559ed0 100644
--- a/core/lib/Drupal/Core/Render/Element/File.php
+++ b/core/lib/Drupal/Core/Render/Element/File.php
@@ -49,7 +49,7 @@ public static function processFile(&$element, FormStateInterface $form_state, &$
   }
 
   /**
-   * Prepares a #type 'file' render element for theme_input().
+   * Prepares a #type 'file' render element for input.html.twig.
    *
    * For assistance with handling the uploaded file correctly, see the API
    * provided by file.inc.
@@ -60,7 +60,7 @@ public static function processFile(&$element, FormStateInterface $form_state, &$
    *   #attributes.
    *
    * @return array
-   *   The $element with prepared variables ready for theme_input().
+   *   The $element with prepared variables ready for input.html.twig.
    */
   public static function preRenderFile($element) {
     $element['#attributes']['type'] = 'file';
diff --git a/core/lib/Drupal/Core/Render/Element/Hidden.php b/core/lib/Drupal/Core/Render/Element/Hidden.php
index bb955afb0f39cd064596d9e4e78ec400fbcbf85f..0da3405e00a10303937d160d823dd42fbe972833 100644
--- a/core/lib/Drupal/Core/Render/Element/Hidden.php
+++ b/core/lib/Drupal/Core/Render/Element/Hidden.php
@@ -36,14 +36,14 @@ public function getInfo() {
   }
 
   /**
-   * Prepares a #type 'hidden' render element for theme_input().
+   * Prepares a #type 'hidden' render element for input.html.twig.
    *
    * @param array $element
    *   An associative array containing the properties of the element.
    *   Properties used: #name, #value, #attributes.
    *
    * @return array
-   *   The $element with prepared variables ready for theme_input().
+   *   The $element with prepared variables ready for input.html.twig.
    */
   public static function preRenderHidden($element) {
     $element['#attributes']['type'] = 'hidden';
diff --git a/core/lib/Drupal/Core/Render/Element/Number.php b/core/lib/Drupal/Core/Render/Element/Number.php
index 5e395414384be48ffa26d49b4c084d6a96cf00c1..20cbee69ef3ba804df1e4d98f24a16a8ffc6398e 100644
--- a/core/lib/Drupal/Core/Render/Element/Number.php
+++ b/core/lib/Drupal/Core/Render/Element/Number.php
@@ -81,7 +81,7 @@ public static function validateNumber(&$element, FormStateInterface $form_state,
   }
 
   /**
-   * Prepares a #type 'number' render element for theme_input().
+   * Prepares a #type 'number' render element for input.html.twig.
    *
    * @param array $element
    *   An associative array containing the properties of the element.
@@ -89,7 +89,7 @@ public static function validateNumber(&$element, FormStateInterface $form_state,
    *   #required, #attributes, #step, #size.
    *
    * @return array
-   *   The $element with prepared variables ready for theme_input().
+   *   The $element with prepared variables ready for input.html.twig.
    */
   public static function preRenderNumber($element) {
     $element['#attributes']['type'] = 'number';
diff --git a/core/lib/Drupal/Core/Render/Element/Password.php b/core/lib/Drupal/Core/Render/Element/Password.php
index 48a20cf320e4a39faed4aad49ce3df09e187becb..03e7719a3727cb6a9ffa0fb3ce6ac7dde50190af 100644
--- a/core/lib/Drupal/Core/Render/Element/Password.php
+++ b/core/lib/Drupal/Core/Render/Element/Password.php
@@ -38,7 +38,7 @@ public function getInfo() {
   }
 
   /**
-   * Prepares a #type 'password' render element for theme_input().
+   * Prepares a #type 'password' render element for input.html.twig.
    *
    * @param array $element
    *   An associative array containing the properties of the element.
@@ -46,7 +46,7 @@ public function getInfo() {
    *   #placeholder, #required, #attributes.
    *
    * @return array
-   *   The $element with prepared variables ready for theme_input().
+   *   The $element with prepared variables ready for input.html.twig.
    */
   public static function preRenderPassword($element) {
     $element['#attributes']['type'] = 'password';
diff --git a/core/lib/Drupal/Core/Render/Element/Radio.php b/core/lib/Drupal/Core/Render/Element/Radio.php
index f106d074b88941815b39dc8ee10afadb436b2f33..3b5f1447d4c3bce32535ddd4f447b1c7a92ee2e3 100644
--- a/core/lib/Drupal/Core/Render/Element/Radio.php
+++ b/core/lib/Drupal/Core/Render/Element/Radio.php
@@ -39,7 +39,7 @@ public function getInfo() {
   }
 
   /**
-   * Prepares a #type 'radio' render element for theme_input().
+   * Prepares a #type 'radio' render element for input.html.twig.
    *
    * @param array $element
    *   An associative array containing the properties of the element.
@@ -51,7 +51,7 @@ public function getInfo() {
    *       all the attributes.
    *
    * @return array
-   *   The $element with prepared variables ready for theme_input().
+   *   The $element with prepared variables ready for input.html.twig.
    */
   public static function preRenderRadio($element) {
     $element['#attributes']['type'] = 'radio';
diff --git a/core/lib/Drupal/Core/Render/Element/Range.php b/core/lib/Drupal/Core/Render/Element/Range.php
index 234d92fd29238fb11021b08bda28b768e6feeb6c..67026aa3dc559f2021c00de39b784b83bea0c768 100644
--- a/core/lib/Drupal/Core/Render/Element/Range.php
+++ b/core/lib/Drupal/Core/Render/Element/Range.php
@@ -34,7 +34,7 @@ public function getInfo() {
   }
 
   /**
-   * Prepares a #type 'range' render element for theme_input().
+   * Prepares a #type 'range' render element for input.html.twig.
    *
    * @param array $element
    *   An associative array containing the properties of the element.
@@ -42,7 +42,7 @@ public function getInfo() {
    *   #step.
    *
    * @return array
-   *   The $element with prepared variables ready for theme_input().
+   *   The $element with prepared variables ready for input.html.twig.
    */
   public static function preRenderRange($element) {
     $element['#attributes']['type'] = 'range';
diff --git a/core/lib/Drupal/Core/Render/Element/Search.php b/core/lib/Drupal/Core/Render/Element/Search.php
index dfa70ed42ed0764ca7fd75589f15514888a550aa..be001c1496ea0b02641175959e8afc1306c25069 100644
--- a/core/lib/Drupal/Core/Render/Element/Search.php
+++ b/core/lib/Drupal/Core/Render/Element/Search.php
@@ -43,7 +43,7 @@ public function getInfo() {
   }
 
   /**
-   * Prepares a #type 'search' render element for theme_input().
+   * Prepares a #type 'search' render element for input.html.twig.
    *
    * @param array $element
    *   An associative array containing the properties of the element.
@@ -51,7 +51,7 @@ public function getInfo() {
    *   #placeholder, #required, #attributes.
    *
    * @return array
-   *   The $element with prepared variables ready for theme_input().
+   *   The $element with prepared variables ready for input.html.twig.
    */
   public static function preRenderSearch($element) {
     $element['#attributes']['type'] = 'search';
diff --git a/core/lib/Drupal/Core/Render/Element/Table.php b/core/lib/Drupal/Core/Render/Element/Table.php
index 08c539a14791570f522e6b1b5a879b9296740f74..bec9df04853def8976efb33ae19f846bc733c4d4 100644
--- a/core/lib/Drupal/Core/Render/Element/Table.php
+++ b/core/lib/Drupal/Core/Render/Element/Table.php
@@ -234,10 +234,10 @@ public static function validateTable(&$element, FormStateInterface $form_state,
   }
 
   /**
-   * #pre_render callback to transform children of an element into #rows suitable for theme_table().
+   * #pre_render callback to transform children of an element of #type 'table'.
    *
    * This function converts sub-elements of an element of #type 'table' to be
-   * suitable for theme_table():
+   * suitable for table.html.twig:
    * - The first level of sub-elements are table rows. Only the #attributes
    *   property is taken into account.
    * - The second level of sub-elements is converted into columns for the
@@ -294,7 +294,7 @@ public static function validateTable(&$element, FormStateInterface $form_state,
    *
    * @return array
    *
-   * @see theme_table()
+   * @see template_preprocess_table()
    * @see drupal_process_attached()
    * @see drupal_attach_tabledrag()
    */
diff --git a/core/lib/Drupal/Core/Render/Element/Tableselect.php b/core/lib/Drupal/Core/Render/Element/Tableselect.php
index 08333692ef786b34780ef40ffa5af95500fff5f8..6bfb0afc881ea17eeae72063ba053b9c4c72ec36 100644
--- a/core/lib/Drupal/Core/Render/Element/Tableselect.php
+++ b/core/lib/Drupal/Core/Render/Element/Tableselect.php
@@ -132,11 +132,11 @@ public static function preRenderTableselect($element) {
         // Render the checkbox / radio element.
         $row['data'][] = drupal_render($element[$key]);
 
-        // As theme_table only maps header and row columns by order, create the
-        // correct order by iterating over the header fields.
+        // As table.html.twig only maps header and row columns by order, create
+        // the correct order by iterating over the header fields.
         foreach ($element['#header'] as $fieldname => $title) {
-          // A row cell can span over multiple headers, which means less row cells
-          // than headers could be present.
+          // A row cell can span over multiple headers, which means less row
+          // cells than headers could be present.
           if (isset($element['#options'][$key][$fieldname])) {
             // A header can span over multiple cells and in this case the cells
             // are passed in an array. The order of this array determines the
diff --git a/core/lib/Drupal/Core/Render/Element/Tel.php b/core/lib/Drupal/Core/Render/Element/Tel.php
index 5cd4c5dd1f926a89155227c6b4d793daa8671b0f..977a23b998da2630e87c0a6d8387ed4e21dc70e9 100644
--- a/core/lib/Drupal/Core/Render/Element/Tel.php
+++ b/core/lib/Drupal/Core/Render/Element/Tel.php
@@ -40,7 +40,7 @@ public function getInfo() {
   }
 
   /**
-   * Prepares a #type 'tel' render element for theme_input().
+   * Prepares a #type 'tel' render element for input.html.twig.
    *
    * @param array $element
    *   An associative array containing the properties of the element.
@@ -48,7 +48,7 @@ public function getInfo() {
    *   #placeholder, #required, #attributes.
    *
    * @return array
-   *   The $element with prepared variables ready for theme_input().
+   *   The $element with prepared variables ready for input.html.twig.
    */
   public static function preRenderTel($element) {
     $element['#attributes']['type'] = 'tel';
diff --git a/core/lib/Drupal/Core/Render/Element/Textfield.php b/core/lib/Drupal/Core/Render/Element/Textfield.php
index 43964948bb5ebab269bfa1a9810b2c33e27aa333..f6d9a5d7dabd0f2616d14a648d5821e35028e93e 100644
--- a/core/lib/Drupal/Core/Render/Element/Textfield.php
+++ b/core/lib/Drupal/Core/Render/Element/Textfield.php
@@ -54,7 +54,7 @@ public static function valueCallback(&$element, $input, FormStateInterface $form
   }
 
   /**
-   * Prepares a #type 'textfield' render element for theme_input().
+   * Prepares a #type 'textfield' render element for input.html.twig.
    *
    * @param array $element
    *   An associative array containing the properties of the element.
@@ -62,7 +62,7 @@ public static function valueCallback(&$element, $input, FormStateInterface $form
    *   #placeholder, #required, #attributes.
    *
    * @return array
-   *   The $element with prepared variables ready for theme_input().
+   *   The $element with prepared variables ready for input.html.twig.
    */
   public static function preRenderTextfield($element) {
     $element['#attributes']['type'] = 'text';
diff --git a/core/lib/Drupal/Core/Render/Element/Url.php b/core/lib/Drupal/Core/Render/Element/Url.php
index e8911280c6c5554b3833d7cfb16313b9d6ff96fc..7f923afcd92e7feded6b6204e47484fe0e4bcf73 100644
--- a/core/lib/Drupal/Core/Render/Element/Url.php
+++ b/core/lib/Drupal/Core/Render/Element/Url.php
@@ -59,7 +59,7 @@ public static function validateUrl(&$element, FormStateInterface $form_state, &$
   }
 
   /**
-   * Prepares a #type 'url' render element for theme_input().
+   * Prepares a #type 'url' render element for input.html.twig.
    *
    * @param array $element
    *   An associative array containing the properties of the element.
@@ -67,7 +67,7 @@ public static function validateUrl(&$element, FormStateInterface $form_state, &$
    *   #placeholder, #required, #attributes.
    *
    * @return array
-   *   The $element with prepared variables ready for theme_input().
+   *   The $element with prepared variables ready for input.html.twig.
    */
   public static function preRenderUrl($element) {
     $element['#attributes']['type'] = 'url';
diff --git a/core/modules/block/templates/block-list.html.twig b/core/modules/block/templates/block-list.html.twig
index 474c65457350a45b16ab0aab8174aea33e765e42..854d3ce85fe1aec6e8917fb1c8e3116889692429 100644
--- a/core/modules/block/templates/block-list.html.twig
+++ b/core/modules/block/templates/block-list.html.twig
@@ -5,7 +5,7 @@
  *
  * This template will be used when a block edit form specifies 'block_edit_form'
  * as its #theme callback.  Otherwise, by default, block add/edit forms will be
- * themed by theme_form().
+ * themed by form.html.twig.
  *
  * Available variables:
  * - form: The block add/edit form.
diff --git a/core/modules/book/book.module b/core/modules/book/book.module
index 5a7efe02e1e34dd0e06a4ac93bf1d7223c975b12..fe6e06d6fa964c06e3adf5fe2e811745b2e13e19 100644
--- a/core/modules/book/book.module
+++ b/core/modules/book/book.module
@@ -504,7 +504,7 @@ function template_preprocess_book_node_export_html(&$variables) {
 }
 
 /**
- * Implements template_preprocess_HOOK() for theme_book_tree().
+ * Implements template_preprocess_HOOK() for book-tree.html.twig.
  */
 function template_preprocess_book_tree(&$variables) {
   $variables['tree'] = $variables['tree']['#children'];
diff --git a/core/modules/config_translation/src/Controller/ConfigTranslationMapperList.php b/core/modules/config_translation/src/Controller/ConfigTranslationMapperList.php
index 23007e9463d0e6b35ef922ab7889ec57df6b0d0e..9e5ed09c46d7dc826e66ee03780e3c3b88d39bf2 100644
--- a/core/modules/config_translation/src/Controller/ConfigTranslationMapperList.php
+++ b/core/modules/config_translation/src/Controller/ConfigTranslationMapperList.php
@@ -46,7 +46,7 @@ public static function create(ContainerInterface $container) {
   }
 
   /**
-   * Builds the mappers as a renderable array for theme_table().
+   * Builds the mappers as a renderable array for table.html.twig.
    *
    * @return array
    *   Renderable array with config translation mappers.
diff --git a/core/modules/node/templates/node-edit-form.html.twig b/core/modules/node/templates/node-edit-form.html.twig
index e34baf90bfd816114b177a5828ac52e9eb9d8c36..6d8ac2aca7cd3f90e75b12de21c85a713128faed 100644
--- a/core/modules/node/templates/node-edit-form.html.twig
+++ b/core/modules/node/templates/node-edit-form.html.twig
@@ -7,7 +7,7 @@
  *
  * This template will be used when a node edit form specifies 'node_edit_form'
  * as its #theme callback.  Otherwise, by default, node add/edit forms will be
- * themed by theme_form().
+ * themed by form.html.twig.
  *
  * Available variables:
  * - form: The node add/edit form.
diff --git a/core/modules/rdf/rdf.module b/core/modules/rdf/rdf.module
index c3fce4f96b992415ccec2792682f92cc9756f23a..50b6f36eb94a396e11c4456c808edeca323764c3 100644
--- a/core/modules/rdf/rdf.module
+++ b/core/modules/rdf/rdf.module
@@ -372,7 +372,7 @@ function rdf_preprocess_user(&$variables) {
 }
 
 /**
- * Implements hook_preprocess_HOOK() for theme_username().
+ * Implements hook_preprocess_HOOK() for username.html.twig.
  */
 function rdf_preprocess_username(&$variables) {
   // Because lang is set on the HTML element that wraps the page, the
@@ -538,7 +538,7 @@ function rdf_preprocess_taxonomy_term(&$variables) {
 }
 
 /**
- * Implements hook_preprocess_HOOK() for theme_image().
+ * Implements hook_preprocess_HOOK() for image.html.twig.
  */
 function rdf_preprocess_image(&$variables) {
   // Adds the RDF type for image.  We cannot use the usual entity-based mapping
diff --git a/core/modules/system/css/system.theme.css b/core/modules/system/css/system.theme.css
index 48fc3dd78a83afc8e91729136713d77b5e00ad55..338866bd9e3449a417115dd37e183fe51bcdd970 100644
--- a/core/modules/system/css/system.theme.css
+++ b/core/modules/system/css/system.theme.css
@@ -11,7 +11,7 @@
 }
 
 /**
- * Markup generated by theme_tablesort_indicator().
+ * Markup generated by tablesort-indicator.html.twig.
  */
 th.active img {
   display: inline;
@@ -21,7 +21,7 @@ td.active {
 }
 
 /**
- * Markup generated by theme_item_list().
+ * Markup generated by item-list.html.twig.
  */
 .item-list .title {
   font-weight: bold;
@@ -398,7 +398,7 @@ ul.links a.active {
 }
 
 /**
- * Markup generated by theme_breadcrumb().
+ * Markup generated by breadcrumb.html.twig.
  */
 .breadcrumb {
   padding-bottom: 0.5em;
diff --git a/core/modules/system/src/SystemManager.php b/core/modules/system/src/SystemManager.php
index 145705fee88f6d3edcd9b789fe3dd974361f569b..010745342e7e1842a827b619988ce466c72e68c8 100644
--- a/core/modules/system/src/SystemManager.php
+++ b/core/modules/system/src/SystemManager.php
@@ -195,7 +195,7 @@ public function getBlockContents() {
    *   The menu item to be displayed.
    *
    * @return array
-   *   An array of menu items, as expected by theme_admin_block_content().
+   *   An array of menu items, as expected by admin-block-content.html.twig.
    */
   public function getAdminBlock(MenuLinkInterface $instance) {
     $content = array();
diff --git a/core/modules/system/src/Tests/Theme/FunctionsTest.php b/core/modules/system/src/Tests/Theme/FunctionsTest.php
index f9a4a832aa4fbc16086f299916f34ed9e94b0984..c1ad1c7e4da1ebfd7bf310d8de189719c1484a0c 100644
--- a/core/modules/system/src/Tests/Theme/FunctionsTest.php
+++ b/core/modules/system/src/Tests/Theme/FunctionsTest.php
@@ -28,7 +28,7 @@ class FunctionsTest extends WebTestBase {
   public static $modules = array('router_test');
 
   /**
-   * Tests theme_item_list().
+   * Tests item-list.html.twig.
    */
   function testItemList() {
     // Verify that empty items produce no output.
diff --git a/core/modules/views/src/Plugin/views/PluginBase.php b/core/modules/views/src/Plugin/views/PluginBase.php
index eba31359117e7305d4c1f16b5feee5dad6f0a454..831d60876264a15c35304d723d0b819f6aeb1eca 100644
--- a/core/modules/views/src/Plugin/views/PluginBase.php
+++ b/core/modules/views/src/Plugin/views/PluginBase.php
@@ -29,9 +29,8 @@
  *   template engine extension).
  *   If a template file should be used, the file has to be placed in the
  *   module's templates folder.
- *   Example: theme = "mymodule_row" of module "mymodule" will implement either
- *   theme_mymodule_row() or mymodule-row.html.twig in the
- *   [..]/modules/mymodule/templates folder.
+ *   Example: theme = "mymodule_row" of module "mymodule" will implement
+ *   mymodule-row.html.twig in the [..]/modules/mymodule/templates folder.
  * - register_theme: (optional) When set to TRUE (default) the theme is
  *   registered automatically. When set to FALSE the plugin reuses an existing
  *   theme implementation, defined by another module or views plugin.
diff --git a/core/modules/views/views.api.php b/core/modules/views/views.api.php
index a537fe66f6621bd04a194695d380c3a0ea60503f..a0d27ca17ec753ee5c35e66cdb6c7deb191fb9b2 100644
--- a/core/modules/views/views.api.php
+++ b/core/modules/views/views.api.php
@@ -832,7 +832,7 @@ function hook_views_query_alter(ViewExecutable $view, QueryPluginBase $query) {
  *   The view object.
  *
  * @see \Drupal\views_ui\ViewUI
- * @see theme_table()
+ * @see table.html.twig
  */
 function hook_views_preview_info_alter(array &$rows, ViewExecutable $view) {
   // Adds information about the tables being queried by the view to the query