diff --git a/core/includes/theme.inc b/core/includes/theme.inc
index 15ef789..2af07a2 100644
--- a/core/includes/theme.inc
+++ b/core/includes/theme.inc
@@ -253,10 +253,10 @@ function _theme($hook, $variables = array()) {
       }
     }
     if (!$theme_registry->has($hook)) {
-      // Only log a message when not trying theme suggestions ($hook being an
+      // Only trigger an error when not trying theme suggestions ($hook being an
       // array).
       if (!isset($candidate)) {
-        \Drupal::logger('theme')->warning('Theme hook %hook not found.', array('%hook' => $hook));
+        trigger_error(sprintf("Unknown theme hook '%s'.", $original_hook), E_USER_ERROR);
       }
       // There is no theme implementation for the hook passed. Return FALSE so
       // the function calling _theme() can differentiate between a hook that
@@ -380,6 +380,10 @@ function _theme($hook, $variables = array()) {
     if (function_exists($info['function'])) {
       $output = SafeMarkup::set($info['function']($variables));
     }
+    else {
+      // The function is registered but does not exist (yet).
+      trigger_error(sprintf("Missing theme function '%s' for theme hook '%s'. Either rebuild the theme registry and/or correct the definition.", $info['function'], $hook), E_USER_WARNING);
+    }
   }
   else {
     $render_function = 'twig_render_template';
diff --git a/core/modules/toolbar/toolbar.module b/core/modules/toolbar/toolbar.module
index 788378c..5ad755d 100644
--- a/core/modules/toolbar/toolbar.module
+++ b/core/modules/toolbar/toolbar.module
@@ -52,10 +52,6 @@ function toolbar_theme($existing, $type, $theme, $path) {
     'render element' => 'element',
     'template' => 'toolbar',
   );
-  $items['toolbar_item'] = array(
-    'render element' => 'element',
-  );
-
   return $items;
 }
 
@@ -98,7 +94,6 @@ function toolbar_element_info() {
   // property contains a renderable array.
   $elements['toolbar_item'] = array(
     '#pre_render' => array('toolbar_pre_render_item'),
-    '#theme' => 'toolbar_item',
     'tab' => array(
       '#type' => 'link',
       '#title' => NULL,
