diff --git a/core/modules/aggregator/aggregator.api.php b/core/modules/aggregator/aggregator.api.php
index a6cb1c5..8f863b3 100644
--- a/core/modules/aggregator/aggregator.api.php
+++ b/core/modules/aggregator/aggregator.api.php
@@ -161,7 +161,7 @@ function hook_aggregator_process($feed) {
  *
  * @ingroup aggregator
  */
-function hook_aggregator_process_info($feed) {
+function hook_aggregator_process_info() {
   return array(
     'title' => t('Default processor'),
     'description' => t('Creates lightweight records of feed items.'),
diff --git a/core/modules/aggregator/aggregator.module b/core/modules/aggregator/aggregator.module
index 8cd7bb8..2775f46 100644
--- a/core/modules/aggregator/aggregator.module
+++ b/core/modules/aggregator/aggregator.module
@@ -50,7 +50,7 @@ function aggregator_help($path, $arg) {
 /**
  * Implements hook_theme().
  */
-function aggregator_theme() {
+function aggregator_theme($existing, $type, $theme, $path) {
   return array(
     'aggregator_categorize_items' => array(
       'render element' => 'form',
diff --git a/core/modules/aggregator/aggregator.processor.inc b/core/modules/aggregator/aggregator.processor.inc
index 54ae7a5..38bd551 100644
--- a/core/modules/aggregator/aggregator.processor.inc
+++ b/core/modules/aggregator/aggregator.processor.inc
@@ -85,7 +85,7 @@ function aggregator_aggregator_remove($feed) {
  * Form alter aggregator module's own form to keep processor functionality
  * separate from aggregator API functionality.
  */
-function aggregator_form_aggregator_admin_form_alter(&$form, $form_state) {
+function aggregator_form_aggregator_admin_form_alter(&$form, $form_state, $form_id) {
   $config = config('aggregator.settings');
   $aggregator_processors = $config->get('processors');
   if (in_array('aggregator', $aggregator_processors)) {
diff --git a/core/modules/block/block.module b/core/modules/block/block.module
index 8bf4aae..aeb57cf 100644
--- a/core/modules/block/block.module
+++ b/core/modules/block/block.module
@@ -81,7 +81,7 @@ function block_help($path, $arg) {
 /**
  * Implements hook_theme().
  */
-function block_theme() {
+function block_theme($existing, $type, $theme, $path) {
   return array(
     'block' => array(
       'render element' => 'elements',
diff --git a/core/modules/book/book.module b/core/modules/book/book.module
index 653ba54..b8e4ecf 100644
--- a/core/modules/book/book.module
+++ b/core/modules/book/book.module
@@ -39,7 +39,7 @@ function book_help($path, $arg) {
 /**
  * Implements hook_theme().
  */
-function book_theme() {
+function book_theme($existing, $type, $theme, $path) {
   return array(
     'book_navigation' => array(
       'variables' => array('book_link' => NULL),
@@ -936,7 +936,7 @@ function _book_parent_depth_limit($book_link) {
  *
  * @see node_delete_confirm()
  */
-function book_form_node_delete_confirm_alter(&$form, $form_state) {
+function book_form_node_delete_confirm_alter(&$form, $form_state, $form_id) {
   $node = node_load($form['nid']['#value']);
 
   if (isset($node->book) && $node->book['has_children']) {
diff --git a/core/modules/color/color.module b/core/modules/color/color.module
index 87d0a37..0962ef2 100644
--- a/core/modules/color/color.module
+++ b/core/modules/color/color.module
@@ -25,7 +25,7 @@ function color_help($path, $arg) {
 /**
  * Implements hook_theme().
  */
-function color_theme() {
+function color_theme($existing, $type, $theme, $path) {
   return array(
     'color_scheme_form' => array(
       'render element' => 'form',
@@ -36,7 +36,7 @@ function color_theme() {
 /**
  * Implements hook_form_FORM_ID_alter().
  */
-function color_form_system_theme_settings_alter(&$form, &$form_state) {
+function color_form_system_theme_settings_alter(&$form, &$form_state, $form_id) {
   if (isset($form_state['build_info']['args'][0]) && ($theme = $form_state['build_info']['args'][0]) && color_get_info($theme) && function_exists('gd_info')) {
     $form['color'] = array(
       '#type' => 'details',
@@ -60,7 +60,7 @@ function color_form_system_theme_settings_alter(&$form, &$form_state) {
  *
  * @see theme()
  */
-function _color_html_alter(&$vars) {
+function _color_html_alter(&$variables) {
   global $theme_key;
   $themes = list_themes();
 
@@ -77,12 +77,12 @@ function _color_html_alter(&$vars) {
         if (drupal_basename($old_path) == drupal_basename($color_path)) {
           // Replace the path to the new css file.
           // This keeps the order of the stylesheets intact.
-          $vars['css'][drupal_basename($old_path)]['data'] = $color_path;
+          $variables['css'][drupal_basename($old_path)]['data'] = $color_path;
         }
       }
     }
 
-    $vars['styles'] = drupal_get_css($vars['css']);
+    $variables['styles'] = drupal_get_css($variables['css']);
   }
 }
 
@@ -95,13 +95,13 @@ function _color_html_alter(&$vars) {
  *
  * @see theme()
  */
-function _color_page_alter(&$vars) {
+function _color_page_alter(&$variables) {
   global $theme_key;
 
   // Override logo.
   $logo = variable_get('color_' . $theme_key . '_logo');
-  if ($logo && $vars['logo'] && preg_match('!' . $theme_key . '/logo.png$!', $vars['logo'])) {
-    $vars['logo'] = file_create_url($logo);
+  if ($logo && $variables['logo'] && preg_match('!' . $theme_key . '/logo.png$!', $variables['logo'])) {
+    $variables['logo'] = file_create_url($logo);
   }
 }
 
diff --git a/core/modules/comment/comment.api.php b/core/modules/comment/comment.api.php
index 793d9ad..014652e 100644
--- a/core/modules/comment/comment.api.php
+++ b/core/modules/comment/comment.api.php
@@ -69,7 +69,7 @@ function hook_comment_create(\Drupal\comment\Plugin\Core\Entity\Comment $comment
  * @param array $comments
  *  An array of comment objects indexed by cid.
  */
-function hook_comment_load(Drupal\comment\Comment $comments) {
+function hook_comment_load($comments) {
   $result = db_query('SELECT cid, foo FROM {mytable} WHERE cid IN (:cids)', array(':cids' => array_keys($comments)));
   foreach ($result as $record) {
     $comments[$record->cid]->foo = $record->foo;
diff --git a/core/modules/comment/comment.module b/core/modules/comment/comment.module
index 6f2795a..30e19cf 100644
--- a/core/modules/comment/comment.module
+++ b/core/modules/comment/comment.module
@@ -195,7 +195,7 @@ function comment_field_extra_fields() {
 /**
  * Implements hook_theme().
  */
-function comment_theme() {
+function comment_theme($existing, $type, $theme, $path) {
   return array(
     'comment_block' => array(
       'variables' => array('number' => NULL),
@@ -1012,7 +1012,7 @@ function comment_view_multiple($comments, $view_mode = 'full', $langcode = NULL)
 /**
  * Implements hook_form_FORM_ID_alter().
  */
-function comment_form_node_type_form_alter(&$form, $form_state) {
+function comment_form_node_type_form_alter(&$form, $form_state, $form_id) {
   if (isset($form['type'])) {
     $form['comment'] = array(
       '#type' => 'details',
@@ -1117,7 +1117,7 @@ function comment_translation_configuration_element_submit($form, &$form_state) {
 /**
  * Implements hook_form_BASE_FORM_ID_alter().
  */
-function comment_form_node_form_alter(&$form, $form_state) {
+function comment_form_node_form_alter(&$form, $form_state, $form_id) {
   $node = $form_state['controller']->getEntity($form_state);
   $form['comment_settings'] = array(
     '#type' => 'details',
diff --git a/core/modules/contact/contact.module b/core/modules/contact/contact.module
index 6e22fe7..9a82bba 100644
--- a/core/modules/contact/contact.module
+++ b/core/modules/contact/contact.module
@@ -330,7 +330,7 @@ function contact_mail($key, &$message, $params) {
  *
  * @see user_profile_form()
  */
-function contact_form_user_profile_form_alter(&$form, &$form_state) {
+function contact_form_user_profile_form_alter(&$form, &$form_state, $form_id) {
   $form['contact'] = array(
     '#type' => 'details',
     '#title' => t('Contact settings'),
@@ -362,7 +362,7 @@ function contact_user_update($account) {
  *
  * @see user_admin_settings()
  */
-function contact_form_user_admin_settings_alter(&$form, &$form_state) {
+function contact_form_user_admin_settings_alter(&$form, &$form_state, $form_id) {
   $form['contact'] = array(
     '#type' => 'details',
     '#title' => t('Contact settings'),
diff --git a/core/modules/dblog/dblog.module b/core/modules/dblog/dblog.module
index a0afcd4..115964e 100644
--- a/core/modules/dblog/dblog.module
+++ b/core/modules/dblog/dblog.module
@@ -164,7 +164,7 @@ function dblog_watchdog(array $log_entry) {
 /**
  * Implements hook_form_FORM_ID_alter() for system_logging_settings().
  */
-function dblog_form_system_logging_settings_alter(&$form, $form_state) {
+function dblog_form_system_logging_settings_alter(&$form, $form_state, $form_id) {
   $form['dblog_row_limit'] = array(
     '#type' => 'select',
     '#title' => t('Database log messages to keep'),
@@ -188,7 +188,7 @@ function dblog_logging_settings_submit($form, &$form_state) {
 /**
  * Implements hook_theme().
  */
-function dblog_theme() {
+function dblog_theme($existing, $type, $theme, $path) {
   return array(
     'dblog_message' => array(
       'variables' => array('event' => NULL, 'link' => FALSE),
diff --git a/core/modules/field/field.module b/core/modules/field/field.module
index 36bd18a..48cd5a8 100644
--- a/core/modules/field/field.module
+++ b/core/modules/field/field.module
@@ -304,7 +304,7 @@ function field_help($path, $arg) {
 /**
  * Implements hook_theme().
  */
-function field_theme() {
+function field_theme($existing, $type, $theme, $path) {
   return array(
     'field' => array(
       'render element' => 'element',
diff --git a/core/modules/field/tests/modules/field_test/field_test.module b/core/modules/field/tests/modules/field_test/field_test.module
index 03094dd..046ed99 100644
--- a/core/modules/field/tests/modules/field_test/field_test.module
+++ b/core/modules/field/tests/modules/field_test/field_test.module
@@ -1,5 +1,6 @@
 <?php
 
+use Drupal\Core\Database\Query\AlterableInterface;
 use Drupal\Core\Entity\EntityInterface;
 
 /**
@@ -257,7 +258,7 @@ function field_test_field_widget_form_alter(&$element, &$form_state, $context) {
  *
  * @see Drupal\system\Tests\Entity\EntityFieldQueryTest::testTablePrefixing()
  */
-function field_test_query_efq_table_prefixing_test_alter(&$query) {
+function field_test_query_efq_table_prefixing_test_alter(AlterableInterface &$query) {
   // Add an additional join onto the entity base table. This will cause an
   // exception if the EFQ does not properly prefix the base table.
   $query->join('test_entity','te2','%alias.ftid = test_entity.ftid');
diff --git a/core/modules/field_ui/field_ui.module b/core/modules/field_ui/field_ui.module
index b9d1a1c..2ecc38d 100644
--- a/core/modules/field_ui/field_ui.module
+++ b/core/modules/field_ui/field_ui.module
@@ -294,7 +294,7 @@ function _field_ui_view_mode_menu_access($entity_type, $bundle, $view_mode, $per
 /**
  * Implements hook_theme().
  */
-function field_ui_theme() {
+function field_ui_theme($existing, $type, $theme, $path) {
   return array(
     'field_ui_table' => array(
       'render element' => 'elements',
@@ -377,7 +377,7 @@ function field_ui_inactive_instances($entity_type, $bundle_name = NULL) {
  * @see node_type_form()
  * @see field_ui_form_node_type_form_submit()
  */
-function field_ui_form_node_type_form_alter(&$form, $form_state) {
+function field_ui_form_node_type_form_alter(&$form, $form_state, $form_id) {
   // We want to display the button only on add page.
   if (empty($form['#node_type']->type)) {
     $form['actions']['save_continue'] = array(
diff --git a/core/modules/file/file.module b/core/modules/file/file.module
index 913f75a..0763816 100644
--- a/core/modules/file/file.module
+++ b/core/modules/file/file.module
@@ -582,7 +582,7 @@ function file_get_content_headers(File $file) {
 /**
  * Implements hook_theme().
  */
-function file_theme() {
+function file_theme($existing, $type, $theme, $path) {
   return array(
     // file.module.
     'file_link' => array(
diff --git a/core/modules/filter/filter.module b/core/modules/filter/filter.module
index dfb5d68..1412122 100644
--- a/core/modules/filter/filter.module
+++ b/core/modules/filter/filter.module
@@ -72,7 +72,7 @@ function filter_help($path, $arg) {
 /**
  * Implements hook_theme().
  */
-function filter_theme() {
+function filter_theme($existing, $type, $theme, $path) {
   return array(
     'filter_admin_format_filter_order' => array(
       'render element' => 'element',
diff --git a/core/modules/forum/forum.module b/core/modules/forum/forum.module
index 872eb95..344f68c 100644
--- a/core/modules/forum/forum.module
+++ b/core/modules/forum/forum.module
@@ -5,6 +5,7 @@
  * Provides discussion forums.
  */
 
+use Drupal\comment\Plugin\Core\Entity\Comment;
 use Drupal\Core\Entity\EntityInterface;
 use Drupal\node\Plugin\Core\Entity\Node;
 use Drupal\entity\Plugin\Core\Entity\EntityDisplay;
@@ -59,7 +60,7 @@ function forum_help($path, $arg) {
 /**
  * Implements hook_theme().
  */
-function forum_theme() {
+function forum_theme($existing, $type, $theme, $path) {
   return array(
     'forums' => array(
       'template' => 'forums',
@@ -485,7 +486,7 @@ function forum_taxonomy_term_delete(Term $term) {
  * This actually handles the insertion and update of published nodes since
  * comment_save() calls hook_comment_publish() for all published comments.
  */
-function forum_comment_publish($comment) {
+function forum_comment_publish(Comment $comment) {
   _forum_update_forum_index($comment->nid->target_id);
 }
 
@@ -495,7 +496,7 @@ function forum_comment_publish($comment) {
  * The Comment module doesn't call hook_comment_unpublish() when saving
  * individual comments, so we need to check for those here.
  */
-function forum_comment_update($comment) {
+function forum_comment_update(Comment $comment) {
   // comment_save() calls hook_comment_publish() for all published comments,
   // so we need to handle all other values here.
   if (!$comment->status->value) {
@@ -506,14 +507,14 @@ function forum_comment_update($comment) {
 /**
  * Implements hook_comment_unpublish().
  */
-function forum_comment_unpublish($comment) {
+function forum_comment_unpublish(Comment $comment) {
   _forum_update_forum_index($comment->nid->target_id);
 }
 
 /**
  * Implements hook_comment_delete().
  */
-function forum_comment_delete($comment) {
+function forum_comment_delete(Comment $comment) {
   _forum_update_forum_index($comment->nid->target_id);
 }
 
diff --git a/core/modules/image/image.module b/core/modules/image/image.module
index 956eafd..07532b4 100644
--- a/core/modules/image/image.module
+++ b/core/modules/image/image.module
@@ -194,7 +194,7 @@ function image_menu() {
 /**
  * Implements hook_theme().
  */
-function image_theme() {
+function image_theme($existing, $type, $theme, $path) {
   return array(
     // Theme functions in image.module.
     'image_style' => array(
@@ -260,7 +260,7 @@ function image_permission() {
 /**
  * Implements hook_form_FORM_ID_alter().
  */
-function image_form_system_file_system_settings_alter(&$form, &$form_state) {
+function image_form_system_file_system_settings_alter(&$form, &$form_state, $form_id) {
   $form['#submit'][] = 'image_system_file_system_settings_submit';
 }
 
diff --git a/core/modules/language/language.module b/core/modules/language/language.module
index d0b91bf..542aba9 100644
--- a/core/modules/language/language.module
+++ b/core/modules/language/language.module
@@ -187,7 +187,7 @@ function language_permission() {
 /**
  * Implements hook_theme().
  */
-function language_theme() {
+function language_theme($existing, $type, $theme, $path) {
   return array(
     'language_negotiation_configure_form' => array(
       'render element' => 'form',
diff --git a/core/modules/locale/locale.module b/core/modules/locale/locale.module
index 579819e..45eb463 100644
--- a/core/modules/locale/locale.module
+++ b/core/modules/locale/locale.module
@@ -257,7 +257,7 @@ function locale_permission() {
 /**
  * Implements hook_theme().
  */
-function locale_theme() {
+function locale_theme($existing, $type, $theme, $path) {
   return array(
     'locale_translate_edit_form_strings' => array(
       'render element' => 'form',
@@ -492,8 +492,8 @@ function locale_modules_uninstalled($modules) {
  * @todo This is technically wrong. We must not import upon enabling, but upon
  *   initial installation. The theme system is missing an installation hook.
  */
-function locale_themes_enabled($themes) {
-  locale_system_update($themes);
+function locale_themes_enabled($theme_list) {
+  locale_system_update($theme_list);
 }
 
 /**
@@ -698,7 +698,7 @@ function locale_library_info_alter(&$libraries, $module) {
 /**
  * Implements hook_form_FORM_ID_alter() for language_admin_overview_form().
  */
-function locale_form_language_admin_overview_form_alter(&$form, &$form_state) {
+function locale_form_language_admin_overview_form_alter(&$form, &$form_state, $form_id) {
   $languages = $form['languages']['#languages'];
 
   $total_strings = locale_storage()->countStrings();
@@ -746,7 +746,7 @@ function locale_form_language_admin_overview_form_alter(&$form, &$form_state) {
 /**
  * Implements hook_form_FORM_ID_alter() for language_admin_add_form(().
  */
-function locale_form_language_admin_add_form_alter(&$form, &$form_state) {
+function locale_form_language_admin_add_form_alter(&$form, &$form_state, $form_id) {
   $form['predefined_submit']['#submit'][] = 'locale_form_language_admin_add_form_alter_submit';
   $form['custom_language']['submit']['#submit'][] = 'locale_form_language_admin_add_form_alter_submit';
 }
@@ -774,7 +774,7 @@ function locale_form_language_admin_add_form_alter_submit($form, $form_state) {
 /**
  * Implements hook_form_FORM_ID_alter() for language_admin_edit_form().
  */
-function locale_form_language_admin_edit_form_alter(&$form, &$form_state) {
+function locale_form_language_admin_edit_form_alter(&$form, &$form_state, $form_id) {
   if ($form['langcode']['#type'] == 'value' && $form['langcode']['#value'] == 'en') {
     $form['locale_translate_english'] = array(
       '#title' => t('Enable interface translation to English'),
@@ -807,7 +807,7 @@ function locale_translate_english() {
  *
  * Add interface translation directory setting to directories configuration.
  */
-function locale_form_system_file_system_settings_alter(&$form, $form_state) {
+function locale_form_system_file_system_settings_alter(&$form, $form_state, $form_id) {
   $form['locale_translate_file_directory'] = array(
     '#type' => 'textfield',
     '#title' => t('Interface translations directory'),
diff --git a/core/modules/menu/menu.module b/core/modules/menu/menu.module
index 09567cf..ef6826b 100644
--- a/core/modules/menu/menu.module
+++ b/core/modules/menu/menu.module
@@ -179,7 +179,7 @@ function menu_uri(Menu $menu) {
 /**
  * Implements hook_theme().
  */
-function menu_theme() {
+function menu_theme($existing, $type, $theme, $path) {
   return array(
     'menu_overview_form' => array(
       'file' => 'menu.admin.inc',
@@ -552,7 +552,7 @@ function _menu_parent_depth_limit($item) {
  *
  * @see menu_node_submit()
  */
-function menu_form_node_form_alter(&$form, $form_state) {
+function menu_form_node_form_alter(&$form, $form_state, $form_id) {
   // Generate a list of possible parents (not including this link or descendants).
   // @todo This must be handled in a #process handler.
   $node = $form_state['controller']->getEntity($form_state);
@@ -670,7 +670,7 @@ function menu_node_submit(Node $node, $form, $form_state) {
  *
  * Adds menu options to the node type form.
  */
-function menu_form_node_type_form_alter(&$form, $form_state) {
+function menu_form_node_type_form_alter(&$form, $form_state, $form_id) {
   $menu_options = menu_get_menus();
   $type = $form['#node_type'];
   $form['menu'] = array(
diff --git a/core/modules/node/node.module b/core/modules/node/node.module
index f2206a0..63d4554 100644
--- a/core/modules/node/node.module
+++ b/core/modules/node/node.module
@@ -145,7 +145,7 @@ function node_help($path, $arg) {
 /**
  * Implements hook_theme().
  */
-function node_theme() {
+function node_theme($existing, $type, $theme, $path) {
   return array(
     'node' => array(
       'render element' => 'elements',
@@ -2339,7 +2339,7 @@ function _node_index_node(Node $node) {
  *
  * @see node_search_validate()
  */
-function node_form_search_form_alter(&$form, $form_state) {
+function node_form_search_form_alter(&$form, $form_state, $form_id) {
   if (isset($form['module']) && $form['module']['#value'] == 'node' && user_access('use advanced search')) {
     // Keyword boxes:
     $form['advanced'] = array(
diff --git a/core/modules/node/tests/modules/node_access_test/node_access_test.module b/core/modules/node/tests/modules/node_access_test/node_access_test.module
index 4efee88..c7e4da3 100644
--- a/core/modules/node/tests/modules/node_access_test/node_access_test.module
+++ b/core/modules/node/tests/modules/node_access_test/node_access_test.module
@@ -180,7 +180,7 @@ function node_access_entity_test_page() {
 /**
  * Implements hook_form_BASE_FORM_ID_alter().
  */
-function node_access_test_form_node_form_alter(&$form, $form_state) {
+function node_access_test_form_node_form_alter(&$form, $form_state, $form_id) {
   // Only show this checkbox for NodeAccessBaseTableTestCase.
   if (state()->get('node_access_test.private')) {
     $node = $form_state['controller']->getEntity($form_state);
diff --git a/core/modules/openid/openid.module b/core/modules/openid/openid.module
index 6d31124..d9027c0 100644
--- a/core/modules/openid/openid.module
+++ b/core/modules/openid/openid.module
@@ -235,7 +235,7 @@ function openid_login_form_submit($form, &$form_state) {
  *
  * Prefills the login form with values acquired via OpenID.
  */
-function openid_form_user_register_form_alter(&$form, &$form_state) {
+function openid_form_user_register_form_alter(&$form, &$form_state, $form_id) {
   if (isset($_SESSION['openid']['response'])) {
     module_load_include('inc', 'openid');
 
diff --git a/core/modules/overlay/overlay.module b/core/modules/overlay/overlay.module
index 383f08a..5ad2b64 100644
--- a/core/modules/overlay/overlay.module
+++ b/core/modules/overlay/overlay.module
@@ -69,7 +69,7 @@ function overlay_permission() {
 /**
  * Implements hook_theme().
  */
-function overlay_theme() {
+function overlay_theme($existing, $type, $theme, $path) {
   return array(
     'overlay' => array(
       'render element' => 'page',
@@ -84,7 +84,7 @@ function overlay_theme() {
 /**
  * Implements hook_form_FORM_ID_alter().
  */
-function overlay_form_user_profile_form_alter(&$form, &$form_state) {
+function overlay_form_user_profile_form_alter(&$form, &$form_state, $form_id) {
   $account = $form_state['controller']->getEntity($form_state);
   if (user_access('access overlay', $account)) {
     $account_data = drupal_container()->get('user.data')->get('overlay', $account->id(), 'enabled');
@@ -170,7 +170,7 @@ function overlay_init() {
  * When viewing an overlay child page, check if we need to trigger a refresh of
  * the supplemental regions of the overlay on the next page request.
  */
-function overlay_exit() {
+function overlay_exit($destination = NULL) {
   // Check that we are in an overlay child page. Note that this should never
   // return TRUE on a cached page view, since the child mode is not set until
   // overlay_init() is called.
diff --git a/core/modules/path/path.module b/core/modules/path/path.module
index 7d3fadd..1a66d81 100644
--- a/core/modules/path/path.module
+++ b/core/modules/path/path.module
@@ -99,7 +99,7 @@ function path_menu() {
  *
  * @see path_form_element_validate()
  */
-function path_form_node_form_alter(&$form, $form_state) {
+function path_form_node_form_alter(&$form, $form_state, $form_id) {
   $node = $form_state['controller']->getEntity($form_state);
   $path = array();
   if (!empty($node->nid)) {
@@ -232,7 +232,7 @@ function path_node_predelete(Node $node) {
 /**
  * Implements hook_form_FORM_ID_alter() for taxonomy_term_form().
  */
-function path_form_taxonomy_term_form_alter(&$form, $form_state) {
+function path_form_taxonomy_term_form_alter(&$form, $form_state, $form_id) {
   // Make sure this does not show up on the delete confirmation form.
   if (empty($form_state['confirm_delete'])) {
     $term = $form_state['controller']->getEntity($form_state);
diff --git a/core/modules/rdf/rdf.module b/core/modules/rdf/rdf.module
index 255fc97..81e0879 100644
--- a/core/modules/rdf/rdf.module
+++ b/core/modules/rdf/rdf.module
@@ -427,7 +427,7 @@ function rdf_comment_load($comments) {
 /**
  * Implements hook_theme().
  */
-function rdf_theme() {
+function rdf_theme($existing, $type, $theme, $path) {
   return array(
     'rdf_template_variable_wrapper' => array(
       'variables' => array('content' => NULL, 'attributes' => array(), 'context' => array(), 'inline' => TRUE),
diff --git a/core/modules/search/search.module b/core/modules/search/search.module
index 375c43f..e4d8a3c 100644
--- a/core/modules/search/search.module
+++ b/core/modules/search/search.module
@@ -5,6 +5,7 @@
  * Enables site-wide keyword searching.
  */
 
+use Drupal\comment\Plugin\Core\Entity\Comment;
 use Drupal\node\Plugin\Core\Entity\Node;
 
 /**
@@ -101,7 +102,7 @@ function search_help($path, $arg) {
 /**
  * Implements hook_theme().
  */
-function search_theme() {
+function search_theme($existing, $type, $theme, $path) {
   return array(
     'search_result' => array(
       'variables' => array('result' => NULL, 'module' => NULL),
@@ -816,7 +817,7 @@ function search_node_update(Node $node) {
 /**
  * Implements hook_comment_insert().
  */
-function search_comment_insert($comment) {
+function search_comment_insert(Comment $comment) {
   // Reindex the node when comments are added.
   search_touch_node($comment->nid->target_id);
 }
@@ -824,7 +825,7 @@ function search_comment_insert($comment) {
 /**
  * Implements hook_comment_update().
  */
-function search_comment_update($comment) {
+function search_comment_update(Comment $comment) {
   // Reindex the node when comments are changed.
   search_touch_node($comment->nid->target_id);
 }
@@ -832,7 +833,7 @@ function search_comment_update($comment) {
 /**
  * Implements hook_comment_delete().
  */
-function search_comment_delete($comment) {
+function search_comment_delete(Comment $comment) {
   // Reindex the node when comments are deleted.
   search_touch_node($comment->nid->target_id);
 }
@@ -840,7 +841,7 @@ function search_comment_delete($comment) {
 /**
  * Implements hook_comment_publish().
  */
-function search_comment_publish($comment) {
+function search_comment_publish(Comment $comment) {
   // Reindex the node when comments are published.
   search_touch_node($comment->nid->target_id);
 }
@@ -848,7 +849,7 @@ function search_comment_publish($comment) {
 /**
  * Implements hook_comment_unpublish().
  */
-function search_comment_unpublish($comment) {
+function search_comment_unpublish(Comment $comment) {
   // Reindex the node when comments are unpublished.
   search_touch_node($comment->nid->target_id);
 }
@@ -1325,8 +1326,8 @@ function _search_excerpt_match_filter($var) {
 /**
  * Implements hook_forms().
  */
-function search_forms() {
-  $forms['search_block_form']= array(
+function search_forms($form_id, $args) {
+  $forms['search_block_form'] = array(
     'callback' => 'search_box',
     'callback arguments' => array('search_block_form'),
   );
diff --git a/core/modules/shortcut/shortcut.module b/core/modules/shortcut/shortcut.module
index 237456a..5052e51 100644
--- a/core/modules/shortcut/shortcut.module
+++ b/core/modules/shortcut/shortcut.module
@@ -167,7 +167,7 @@ function shortcut_admin_paths() {
 /**
  * Implements hook_theme().
  */
-function shortcut_theme() {
+function shortcut_theme($existing, $type, $theme, $path) {
   return array(
     'shortcut_set_customize' => array(
       'render element' => 'form',
diff --git a/core/modules/simpletest/simpletest.module b/core/modules/simpletest/simpletest.module
index d7adb65..b83a779 100644
--- a/core/modules/simpletest/simpletest.module
+++ b/core/modules/simpletest/simpletest.module
@@ -78,7 +78,7 @@ function simpletest_permission() {
 /**
  * Implements hook_theme().
  */
-function simpletest_theme() {
+function simpletest_theme($existing, $type, $theme, $path) {
   return array(
     'simpletest_test_table' => array(
       'render element' => 'table',
diff --git a/core/modules/syslog/syslog.module b/core/modules/syslog/syslog.module
index 8af77c1..9e0b927 100644
--- a/core/modules/syslog/syslog.module
+++ b/core/modules/syslog/syslog.module
@@ -44,7 +44,7 @@ function syslog_help($path, $arg) {
 /**
  * Implements hook_form_FORM_ID_alter().
  */
-function syslog_form_system_logging_settings_alter(&$form, &$form_state) {
+function syslog_form_system_logging_settings_alter(&$form, &$form_state, $form_id) {
   $config = config('syslog.settings');
   $help = module_exists('help') ? ' ' . l(t('More information'), 'admin/help/syslog') . '.' : NULL;
   $form['syslog_identity'] = array(
diff --git a/core/modules/system/system.api.php b/core/modules/system/system.api.php
index ba82bd4..16081f8 100644
--- a/core/modules/system/system.api.php
+++ b/core/modules/system/system.api.php
@@ -912,20 +912,20 @@ function hook_menu_alter(&$items) {
  *
  * @see hook_translated_menu_link_alter()
  */
-function hook_menu_link_alter(&$item) {
+function hook_menu_link_alter(&$link) {
   // Make all new admin links hidden (a.k.a disabled).
-  if (strpos($item['link_path'], 'admin') === 0 && empty($item['mlid'])) {
-    $item['hidden'] = 1;
+  if (strpos($link['link_path'], 'admin') === 0 && empty($link['mlid'])) {
+    $link['hidden'] = 1;
   }
   // Flag a link to be altered by hook_translated_menu_link_alter().
-  if ($item['link_path'] == 'devel/cache/clear') {
-    $item['options']['alter'] = TRUE;
+  if ($link['link_path'] == 'devel/cache/clear') {
+    $link['options']['alter'] = TRUE;
   }
   // Flag a link to be altered by hook_translated_menu_link_alter(), but only
   // if it is derived from a menu router item; i.e., do not alter a custom
   // menu link pointing to the same path that has been created by a user.
-  if ($item['link_path'] == 'user' && $item['module'] == 'system') {
-    $item['options']['alter'] = TRUE;
+  if ($link['link_path'] == 'user' && $link['module'] == 'system') {
+    $link['options']['alter'] = TRUE;
   }
 }
 
@@ -953,9 +953,9 @@ function hook_menu_link_alter(&$item) {
  *
  * @see hook_menu_link_alter()
  */
-function hook_translated_menu_link_alter(&$item, $map) {
-  if ($item['href'] == 'devel/cache/clear') {
-    $item['localized_options']['query'] = drupal_get_destination();
+function hook_translated_menu_link_alter(&$link, $map) {
+  if ($link['href'] == 'devel/cache/clear') {
+    $link['localized_options']['query'] = drupal_get_destination();
   }
 }
 
diff --git a/core/modules/system/system.module b/core/modules/system/system.module
index 8ba745c..2ab3ae1 100644
--- a/core/modules/system/system.module
+++ b/core/modules/system/system.module
@@ -131,7 +131,7 @@ function system_help($path, $arg) {
 /**
  * Implements hook_theme().
  */
-function system_theme() {
+function system_theme($existing, $type, $theme, $path) {
   return array_merge(drupal_common_theme(), array(
     'system_themes_page' => array(
       'variables' => array('theme_groups' => NULL),
@@ -2563,7 +2563,7 @@ function system_custom_theme() {
 /**
  * Implements hook_form_FORM_ID_alter().
  */
-function system_form_user_profile_form_alter(&$form, &$form_state) {
+function system_form_user_profile_form_alter(&$form, &$form_state, $form_id) {
   if (config('system.timezone')->get('user.configurable')) {
     system_user_timezone($form, $form_state);
   }
@@ -2572,7 +2572,7 @@ function system_form_user_profile_form_alter(&$form, &$form_state) {
 /**
  * Implements hook_form_FORM_ID_alter().
  */
-function system_form_user_register_form_alter(&$form, &$form_state) {
+function system_form_user_register_form_alter(&$form, &$form_state, $form_id) {
   $config = config('system.timezone');
   if ($config->get('user.configurable') && $config->get('user.default') == DRUPAL_USER_TIMEZONE_SELECT) {
     system_user_timezone($form, $form_state);
diff --git a/core/modules/system/tests/modules/form_test/form_test.module b/core/modules/system/tests/modules/form_test/form_test.module
index 8c17e01..e02a74b 100644
--- a/core/modules/system/tests/modules/form_test/form_test.module
+++ b/core/modules/system/tests/modules/form_test/form_test.module
@@ -391,7 +391,7 @@ function form_test_alter_form($form, &$form_state) {
 /**
  * Implements hook_form_FORM_ID_alter() on behalf of block.module.
  */
-function block_form_form_test_alter_form_alter(&$form, &$form_state) {
+function block_form_form_test_alter_form_alter(&$form, &$form_state, $form_id) {
   drupal_set_message('block_form_form_test_alter_form_alter() executed.');
 }
 
@@ -407,14 +407,14 @@ function form_test_form_alter(&$form, &$form_state, $form_id) {
 /**
  * Implements hook_form_FORM_ID_alter().
  */
-function form_test_form_form_test_alter_form_alter(&$form, &$form_state) {
+function form_test_form_form_test_alter_form_alter(&$form, &$form_state, $form_id) {
   drupal_set_message('form_test_form_form_test_alter_form_alter() executed.');
 }
 
 /**
  * Implements hook_form_FORM_ID_alter() on behalf of system.module.
  */
-function system_form_form_test_alter_form_alter(&$form, &$form_state) {
+function system_form_form_test_alter_form_alter(&$form, &$form_state, $form_id) {
   drupal_set_message('system_form_form_test_alter_form_alter() executed.');
 }
 
@@ -2022,7 +2022,7 @@ function form_test_state_persist_submit($form, &$form_state) {
  *
  * @see form_test_state_persist()
  */
-function form_test_form_form_test_state_persist_alter(&$form, &$form_state) {
+function form_test_form_form_test_state_persist_alter(&$form, &$form_state, $form_id) {
   // Simulate a form alter implementation inserting form elements that enable
   // caching of the form, e.g. elements having #ajax.
   if (!empty($_REQUEST['cache'])) {
@@ -2226,7 +2226,7 @@ function form_test_redirect_submit(&$form, &$form_state) {
 /**
  * Implements hook_form_FORM_ID_alter() for the registration form.
  */
-function form_test_form_user_register_form_alter(&$form, &$form_state) {
+function form_test_form_user_register_form_alter(&$form, &$form_state, $form_id) {
   $form['test_rebuild'] = array(
     '#type' => 'submit',
     '#value' => t('Rebuild'),
diff --git a/core/modules/system/tests/modules/menu_test/menu_test.module b/core/modules/system/tests/modules/menu_test/menu_test.module
index 36cef57..ad43402 100644
--- a/core/modules/system/tests/modules/menu_test/menu_test.module
+++ b/core/modules/system/tests/modules/menu_test/menu_test.module
@@ -515,7 +515,7 @@ function menu_test_menu_name($new_name = '') {
  * @return
  *  A random string.
  */
-function menu_test_menu_link_insert($item) {
+function menu_test_menu_link_insert($link) {
   menu_test_static_variable('insert');
 }
 
@@ -525,7 +525,7 @@ function menu_test_menu_link_insert($item) {
  * @return
  *  A random string.
  */
-function menu_test_menu_link_update($item) {
+function menu_test_menu_link_update($link) {
   menu_test_static_variable('update');
 }
 
@@ -535,7 +535,7 @@ function menu_test_menu_link_update($item) {
  * @return
  *  A random string.
  */
-function menu_test_menu_link_delete($item) {
+function menu_test_menu_link_delete($link) {
   menu_test_static_variable('delete');
 }
 
diff --git a/core/modules/system/tests/modules/session_test/session_test.module b/core/modules/system/tests/modules/session_test/session_test.module
index b3e82fd..0105841 100644
--- a/core/modules/system/tests/modules/session_test/session_test.module
+++ b/core/modules/system/tests/modules/session_test/session_test.module
@@ -157,7 +157,7 @@ function session_test_user_login($account) {
 /**
  * Implements hook_form_FORM_ID_alter().
  */
-function session_test_form_user_login_form_alter(&$form) {
+function session_test_form_user_login_form_alter(&$form, $form_state, $form_id) {
   $form['#https'] = TRUE;
 }
 
diff --git a/core/modules/system/tests/modules/system_test/system_test.module b/core/modules/system/tests/modules/system_test/system_test.module
index 4494299..47dbefa 100644
--- a/core/modules/system/tests/modules/system_test/system_test.module
+++ b/core/modules/system/tests/modules/system_test/system_test.module
@@ -231,7 +231,7 @@ function system_test_init() {
 /**
  * Implements hook_exit().
  */
-function system_test_exit() {
+function system_test_exit($destination = NULL) {
   watchdog('system_test', 'hook_exit');
 }
 
@@ -287,7 +287,7 @@ function system_test_lock_acquire() {
 /**
  * Try to acquire a specific lock, and then exit.
  */
-function system_test_lock_exit() {
+function system_test_lock_exit($destination = NULL) {
   if (lock()->acquire('system_test_lock_exit', 900)) {
     echo 'TRUE: Lock successfully acquired in system_test_lock_exit()';
     // The shut-down function should release the lock.
diff --git a/core/modules/system/theme.api.php b/core/modules/system/theme.api.php
index 0001cba..7559f54 100644
--- a/core/modules/system/theme.api.php
+++ b/core/modules/system/theme.api.php
@@ -82,7 +82,7 @@
  * @param $form_state
  *   A keyed array containing the current state of the form.
  */
-function hook_form_system_theme_settings_alter(&$form, &$form_state) {
+function hook_form_system_theme_settings_alter(&$form, &$form_state, $form_id) {
   // Add a checkbox to toggle the breadcrumb trail.
   $form['toggle_breadcrumb'] = array(
     '#type' => 'checkbox',
diff --git a/core/modules/taxonomy/taxonomy.module b/core/modules/taxonomy/taxonomy.module
index 4b1a2b1..59aaef1 100644
--- a/core/modules/taxonomy/taxonomy.module
+++ b/core/modules/taxonomy/taxonomy.module
@@ -236,7 +236,7 @@ function taxonomy_select_nodes($tid, $pager = TRUE, $limit = FALSE, $order = arr
 /**
  * Implements hook_theme().
  */
-function taxonomy_theme() {
+function taxonomy_theme($existing, $type, $theme, $path) {
   return array(
     'taxonomy_overview_vocabularies' => array(
       'render element' => 'form',
diff --git a/core/modules/tracker/tracker.module b/core/modules/tracker/tracker.module
index 30a0dbb..23c332c 100644
--- a/core/modules/tracker/tracker.module
+++ b/core/modules/tracker/tracker.module
@@ -5,6 +5,7 @@
  * Tracks recent content posted by a user or users.
  */
 
+use Drupal\comment\Plugin\Core\Entity\Comment;
 use Drupal\node\Plugin\Core\Entity\Node;
 
 /**
@@ -226,7 +227,7 @@ function tracker_node_predelete(Node $node, $arg = 0) {
  * Comment module doesn't call hook_comment_unpublish() when saving individual
  * comments so we need to check for those here.
  */
-function tracker_comment_update($comment) {
+function tracker_comment_update(Comment $comment) {
   // comment_save() calls hook_comment_publish() for all published comments
   // so we need to handle all other values here.
   if ($comment->status->value != COMMENT_PUBLISHED) {
@@ -240,21 +241,21 @@ function tracker_comment_update($comment) {
  * This actually handles the insert and update of published nodes since
  * comment_save() calls hook_comment_publish() for all published comments.
  */
-function tracker_comment_publish($comment) {
+function tracker_comment_publish(Comment $comment) {
   _tracker_add($comment->nid->target_id, $comment->uid->target_id, $comment->changed->value);
 }
 
 /**
  * Implements hook_comment_unpublish().
  */
-function tracker_comment_unpublish($comment) {
+function tracker_comment_unpublish(Comment $comment) {
   _tracker_remove($comment->nid->target_id, $comment->uid->target_id, $comment->changed->value);
 }
 
 /**
  * Implements hook_comment_delete().
  */
-function tracker_comment_delete($comment) {
+function tracker_comment_delete(Comment $comment) {
   _tracker_remove($comment->nid->target_id, $comment->uid->target_id, $comment->changed->value);
 }
 
diff --git a/core/modules/translation/translation.module b/core/modules/translation/translation.module
index a864120..3d9c738 100644
--- a/core/modules/translation/translation.module
+++ b/core/modules/translation/translation.module
@@ -154,7 +154,7 @@ function translation_user_can_translate_node($node, $account = NULL) {
 /**
  * Implements hook_form_FORM_ID_alter() for node_type_form().
  */
-function translation_form_node_type_form_alter(&$form, &$form_state) {
+function translation_form_node_type_form_alter(&$form, &$form_state, $form_id) {
   // Hide form element if default language is a constant.
   // TODO: When form #states allows OR values change this to use form #states.
   $form['#attached']['library'][] = array('translation', 'drupal.translation');
@@ -191,7 +191,7 @@ function translation_node_type_language_translation_enabled_validate($element, &
  *
  * @see node_form()
  */
-function translation_form_node_form_alter(&$form, &$form_state) {
+function translation_form_node_form_alter(&$form, &$form_state, $form_id) {
   $node = $form_state['controller']->getEntity($form_state);
   if (translation_supported_type($node->type)) {
     if (!empty($node->translation_source)) {
diff --git a/core/modules/update/tests/modules/update_test/update_test.module b/core/modules/update/tests/modules/update_test/update_test.module
index 078bcf5..81c551f 100644
--- a/core/modules/update/tests/modules/update_test/update_test.module
+++ b/core/modules/update/tests/modules/update_test/update_test.module
@@ -50,7 +50,7 @@ function update_test_menu() {
  * theme short name ($file->name) and the subarrays contain settings just for
  * that module or theme.
  */
-function update_test_system_info_alter(&$info, $file) {
+function update_test_system_info_alter(&$info, $file, $type) {
   $setting = config('update_test.settings')->get('system_info');
   foreach (array('#all', $file->name) as $id) {
     if (!empty($setting[$id])) {
diff --git a/core/modules/update/update.module b/core/modules/update/update.module
index 00ef879..009c7c5 100644
--- a/core/modules/update/update.module
+++ b/core/modules/update/update.module
@@ -257,7 +257,7 @@ function update_manager_access() {
 /**
  * Implements hook_theme().
  */
-function update_theme() {
+function update_theme($existing, $type, $theme, $path) {
   return array(
     'update_manager_update_form' => array(
       'render element' => 'form',
@@ -315,7 +315,7 @@ function update_cron() {
  *
  * If themes are enabled, we invalidate the cache of available updates.
  */
-function update_themes_enabled($themes) {
+function update_themes_enabled($theme_list) {
   // Clear all update module caches.
   _update_cache_clear();
 }
@@ -325,7 +325,7 @@ function update_themes_enabled($themes) {
  *
  * If themes are disabled, we invalidate the cache of available updates.
  */
-function update_themes_disabled($themes) {
+function update_themes_disabled($theme_list) {
   // Clear all update module caches.
   _update_cache_clear();
 }
@@ -338,7 +338,7 @@ function update_themes_disabled($themes) {
  *
  * @see _update_cache_clear()
  */
-function update_form_system_modules_alter(&$form, $form_state) {
+function update_form_system_modules_alter(&$form, $form_state, $form_id) {
   $form['#submit'][] = 'update_cache_clear_submit';
 }
 
diff --git a/core/modules/user/user.module b/core/modules/user/user.module
index 6a9fb78..1f390ac 100644
--- a/core/modules/user/user.module
+++ b/core/modules/user/user.module
@@ -87,7 +87,7 @@ function user_help($path, $arg) {
 /**
  * Implements hook_theme().
  */
-function user_theme() {
+function user_theme($existing, $type, $theme, $path) {
   return array(
     'user' => array(
       'render element' => 'elements',
@@ -613,7 +613,7 @@ function user_search_execute($keys = NULL, $conditions = NULL) {
 /**
  * Implements hook_user_view().
  */
-function user_user_view(User $account, EntityDisplay $display) {
+function user_user_view(User $account, EntityDisplay $display, $langcode) {
   if ($display->getComponent('member_for')) {
     $account->content['member_for'] = array(
       '#type' => 'item',
@@ -1151,7 +1151,7 @@ function user_menu_breadcrumb_alter(&$active_trail, $item) {
 /**
  * Implements hook_translated_menu_link_alter().
  */
-function user_translated_menu_link_alter(&$link) {
+function user_translated_menu_link_alter(&$link, $map) {
   // Hide the "User account" link for anonymous users.
   if ($link['link_path'] == 'user' && $link['module'] == 'system' && !$GLOBALS['user']->uid) {
     $link['hidden'] = 1;
diff --git a/core/modules/xmlrpc/tests/modules/xmlrpc_test/xmlrpc_test.module b/core/modules/xmlrpc/tests/modules/xmlrpc_test/xmlrpc_test.module
index 11c86c3..d2a5c57 100644
--- a/core/modules/xmlrpc/tests/modules/xmlrpc_test/xmlrpc_test.module
+++ b/core/modules/xmlrpc/tests/modules/xmlrpc_test/xmlrpc_test.module
@@ -67,11 +67,11 @@ function xmlrpc_test_xmlrpc() {
  *
  * Hide (or not) the system.methodSignature() service depending on a variable.
  */
-function xmlrpc_test_xmlrpc_alter(&$services) {
+function xmlrpc_test_xmlrpc_alter(&$methods) {
   $xmlprc_alter = state()->get('xmlrpc_test.alter') ?: FALSE;
   if ($xmlprc_alter) {
     $remove = NULL;
-    foreach ($services as $key => $value) {
+    foreach ($methods as $key => $value) {
       if (!is_array($value)) {
         continue;
       }
@@ -81,7 +81,7 @@ function xmlrpc_test_xmlrpc_alter(&$services) {
       }
     }
     if (isset($remove)) {
-      unset($services[$remove]);
+      unset($methods[$remove]);
     }
   }
 }
diff --git a/core/profiles/minimal/minimal.profile b/core/profiles/minimal/minimal.profile
index fe6da8c..a3caa15 100644
--- a/core/profiles/minimal/minimal.profile
+++ b/core/profiles/minimal/minimal.profile
@@ -9,7 +9,7 @@
  *
  * Allows the profile to alter the site configuration form.
  */
-function minimal_form_install_configure_form_alter(&$form, $form_state) {
+function minimal_form_install_configure_form_alter(&$form, $form_state, $form_id) {
   // Pre-populate the site name with the server name.
   $form['site_information']['site_name']['#default_value'] = $_SERVER['SERVER_NAME'];
 }
diff --git a/core/profiles/standard/standard.profile b/core/profiles/standard/standard.profile
index d554c93..56d76ed 100644
--- a/core/profiles/standard/standard.profile
+++ b/core/profiles/standard/standard.profile
@@ -9,7 +9,7 @@
  *
  * Allows the profile to alter the site configuration form.
  */
-function standard_form_install_configure_form_alter(&$form, $form_state) {
+function standard_form_install_configure_form_alter(&$form, $form_state, $form_id) {
   // Pre-populate the site name with the server name.
   $form['site_information']['site_name']['#default_value'] = $_SERVER['SERVER_NAME'];
 }
diff --git a/core/themes/seven/template.php b/core/themes/seven/template.php
index d679369..2895e5e 100644
--- a/core/themes/seven/template.php
+++ b/core/themes/seven/template.php
@@ -8,19 +8,19 @@
 /**
  * Implements hook_preprocess_HOOK() for maintenance-page.tpl.php.
  */
-function seven_preprocess_maintenance_page(&$vars) {
+function seven_preprocess_maintenance_page(&$variables) {
   // While markup for normal pages is split into page.tpl.php and html.tpl.php,
   // the markup for the maintenance page is all in the single
   // maintenance-page.tpl.php template. So, to have what's done in
   // seven_preprocess_html() also happen on the maintenance page, it has to be
   // called here.
-  seven_preprocess_html($vars);
+  seven_preprocess_html($variables);
 }
 
 /**
  * Implements hook_preprocess_HOOK() for html.tpl.php.
  */
-function seven_preprocess_html(&$vars) {
+function seven_preprocess_html(&$variables) {
   drupal_add_library('system', 'normalize');
   // Add conditional CSS for IE8 and below.
   drupal_add_css(path_to_theme() . '/ie.css', array('group' => CSS_THEME, 'browsers' => array('IE' => 'lte IE 8', '!IE' => FALSE), 'weight' => 999, 'preprocess' => FALSE));
@@ -29,12 +29,12 @@ function seven_preprocess_html(&$vars) {
 /**
  * Implements hook_preprocess_HOOK() for page.tpl.php.
  */
-function seven_preprocess_page(&$vars) {
-  $vars['primary_local_tasks'] = $vars['tabs'];
-  unset($vars['primary_local_tasks']['#secondary']);
-  $vars['secondary_local_tasks'] = array(
+function seven_preprocess_page(&$variables) {
+  $variables['primary_local_tasks'] = $variables['tabs'];
+  unset($variables['primary_local_tasks']['#secondary']);
+  $variables['secondary_local_tasks'] = array(
     '#theme' => 'menu_local_tasks',
-    '#secondary' => $vars['tabs']['#secondary'],
+    '#secondary' => $variables['tabs']['#secondary'],
   );
 }
 
