diff --git a/includes/bootstrap.inc b/includes/bootstrap.inc
index 06f8c68..c2ff634 100644
--- a/includes/bootstrap.inc
+++ b/includes/bootstrap.inc
@@ -173,7 +173,7 @@ define('LANGUAGE_TYPE_CONTENT', 'language_content');
 /**
  * The type of language used to select the user interface.
  */
-define('LANGUAGE_TYPE_INTERFACE', 'language');
+define('LANGUAGE_TYPE_INTERFACE', 'language_interface');
 
 /**
  * The type of language used for URLs.
@@ -1260,12 +1260,12 @@ function drupal_unpack($obj, $field = 'data') {
  * @ingroup sanitization
  */
 function t($string, array $args = array(), array $options = array()) {
-  global $language;
+  global $language_interface;
   static $custom_strings;
 
   // Merge in default.
   if (empty($options['langcode'])) {
-    $options['langcode'] = isset($language->language) ? $language->language : 'en';
+    $options['langcode'] = isset($language_interface->language) ? $language_interface->language : 'en';
   }
   if (empty($options['context'])) {
     $options['context'] = '';
diff --git a/includes/common.inc b/includes/common.inc
index 481edae..baee842 100644
--- a/includes/common.inc
+++ b/includes/common.inc
@@ -1873,9 +1873,9 @@ function format_date($timestamp, $type = 'medium', $format = '', $timezone = NUL
   }
 
   // Use the default langcode if none is set.
-  global $language;
+  global $language_interface;
   if (empty($langcode)) {
-    $langcode = isset($language->language) ? $language->language : 'en';
+    $langcode = isset($language_interface->language) ? $language_interface->language : 'en';
   }
 
   switch ($type) {
@@ -7279,7 +7279,7 @@ function drupal_check_incompatibility($v, $current_version) {
  *   to return an array with info about all types.
  */
 function entity_get_info($entity_type = NULL) {
-  global $language;
+  global $language_interface;
 
   // Use the advanced drupal_static() pattern, since this is called very often.
   static $drupal_static_fast;
@@ -7290,7 +7290,7 @@ function entity_get_info($entity_type = NULL) {
 
   // hook_entity_info() includes translated strings, so each language is cached
   // separately.
-  $langcode = $language->language;
+  $langcode = $language_interface->language;
 
   if (empty($entity_info)) {
     if ($cache = cache_get("entity_info:$langcode")) {
diff --git a/includes/locale.inc b/includes/locale.inc
index d0b11f8..313a019 100644
--- a/includes/locale.inc
+++ b/includes/locale.inc
@@ -82,8 +82,8 @@ define('LOCALE_LANGUAGE_NEGOTIATION_URL_DOMAIN', 1);
  *   The current interface language code.
  */
 function locale_language_from_interface() {
-  global $language;
-  return isset($language->language) ? $language->language : FALSE;
+  global $language_interface;
+  return isset($language_interface->language) ? $language_interface->language : FALSE;
 }
 
 /**
@@ -1383,8 +1383,6 @@ function _locale_import_parse_quoted($string) {
  * Drupal.formatPlural() and inserts them into the database.
  */
 function _locale_parse_js_file($filepath) {
-  global $language;
-
   // The file path might contain a query string, so make sure we only use the
   // actual file.
   $parsed_url = drupal_parse_url($filepath);
@@ -1725,12 +1723,13 @@ function _locale_invalidate_js($langcode = NULL) {
 /**
  * (Re-)Creates the JavaScript translation file for a language.
  *
- * @param $language
+ * @param $langcode
  *   The language, the translation file should be (re)created for.
  */
 function _locale_rebuild_js($langcode = NULL) {
   if (!isset($langcode)) {
-    global $language;
+    global $language_interface;
+    $language = $language_interface;
   }
   else {
     // Get information about the locale.
diff --git a/includes/menu.inc b/includes/menu.inc
index 7423c99..903cb8e 100644
--- a/includes/menu.inc
+++ b/includes/menu.inc
@@ -1091,7 +1091,7 @@ function menu_tree_all_data($menu_name, $link = NULL, $max_depth = NULL) {
   // Use $mlid as a flag for whether the data being loaded is for the whole tree.
   $mlid = isset($link['mlid']) ? $link['mlid'] : 0;
   // Generate a cache ID (cid) specific for this $menu_name, $link, $language, and depth.
-  $cid = 'links:' . $menu_name . ':all:' . $mlid . ':' . $GLOBALS['language']->language . ':' . (int) $max_depth;
+  $cid = 'links:' . $menu_name . ':all:' . $mlid . ':' . $GLOBALS['language_interface']->language . ':' . (int) $max_depth;
 
   if (!isset($tree[$cid])) {
     // If the static variable doesn't have the data, check {cache_menu}.
@@ -1164,7 +1164,7 @@ function menu_tree_page_data($menu_name, $max_depth = NULL, $only_active_trail =
       $max_depth = min($max_depth, MENU_MAX_DEPTH);
     }
     // Generate a cache ID (cid) specific for this page.
-    $cid = 'links:' . $menu_name . ':page:' . $item['href'] . ':' . $GLOBALS['language']->language . ':' . (int) $item['access'] . ':' . (int) $max_depth;
+    $cid = 'links:' . $menu_name . ':page:' . $item['href'] . ':' . $GLOBALS['language_interface']->language . ':' . (int) $item['access'] . ':' . (int) $max_depth;
     // If we are asked for the active trail only, and $menu_name has not been
     // built and cached for this page yet, then this likely means that it
     // won't be built anymore, as this function is invoked from
@@ -1313,7 +1313,7 @@ function _menu_build_tree($menu_name, array $parameters = array()) {
   if (isset($parameters['expanded'])) {
     sort($parameters['expanded']);
   }
-  $tree_cid = 'links:' . $menu_name . ':tree-data:' . $GLOBALS['language']->language . ':' . hash('sha256', serialize($parameters));
+  $tree_cid = 'links:' . $menu_name . ':tree-data:' . $GLOBALS['language_interface']->language . ':' . hash('sha256', serialize($parameters));
 
   // If we do not have this tree in the static cache, check {cache_menu}.
   if (!isset($trees[$tree_cid])) {
diff --git a/includes/theme.inc b/includes/theme.inc
index 6c2b640..1deeb55 100644
--- a/includes/theme.inc
+++ b/includes/theme.inc
@@ -2194,8 +2194,8 @@ function template_preprocess_html(&$variables) {
   // using an associated GRDDL profile.
   $variables['rdf_namespaces']    = drupal_get_rdf_namespaces();
   $variables['grddl_profile']     = 'http://www.w3.org/1999/xhtml/vocab';
-  $variables['language']          = $GLOBALS['language'];
-  $variables['language']->dir     = $GLOBALS['language']->direction ? 'rtl' : 'ltr';
+  $variables['language']          = $GLOBALS['language_interface'];
+  $variables['language']->dir     = $GLOBALS['language_interface']->direction ? 'rtl' : 'ltr';
 
   // Add favicon.
   if (theme_get_setting('toggle_favicon')) {
@@ -2265,8 +2265,8 @@ function template_preprocess_page(&$variables) {
   $variables['base_path']         = base_path();
   $variables['front_page']        = url();
   $variables['feed_icons']        = drupal_get_feeds();
-  $variables['language']          = $GLOBALS['language'];
-  $variables['language']->dir     = $GLOBALS['language']->direction ? 'rtl' : 'ltr';
+  $variables['language']          = $GLOBALS['language_interface'];
+  $variables['language']->dir     = $GLOBALS['language_interface']->direction ? 'rtl' : 'ltr';
   $variables['logo']              = theme_get_setting('logo');
   $variables['main_menu']         = theme_get_setting('toggle_main_menu') ? menu_main_menu() : array();
   $variables['secondary_menu']    = theme_get_setting('toggle_secondary_menu') ? menu_secondary_menu() : array();
@@ -2464,7 +2464,7 @@ function template_preprocess_maintenance_page(&$variables) {
   }
 
   // set the default language if necessary
-  $language = isset($GLOBALS['language']) ? $GLOBALS['language'] : language_default();
+  $language = isset($GLOBALS['language_interface']) ? $GLOBALS['language_interface'] : language_default();
 
   $variables['head_title_array']  = $head_title;
   $variables['head_title']        = implode(' | ', $head_title);
diff --git a/modules/block/block.api.php b/modules/block/block.api.php
index d33f594..d331ffc 100644
--- a/modules/block/block.api.php
+++ b/modules/block/block.api.php
@@ -319,7 +319,7 @@ function hook_block_view_MODULE_DELTA_alter(&$data, $block) {
  *   An array of $blocks, keyed by the block ID.
  */
 function hook_block_list_alter(&$blocks) {
-  global $language, $theme_key;
+  global $language_interface, $theme_key;
 
   // This example shows how to achieve language specific visibility setting for
   // blocks.
@@ -343,7 +343,7 @@ function hook_block_list_alter(&$blocks) {
       continue;
     }
 
-    if (!isset($block_languages[$block->module][$block->delta][$language->language])) {
+    if (!isset($block_languages[$block->module][$block->delta][$language_interface->language])) {
       // This block should not be displayed with the active language, remove
       // from the list.
       unset($blocks[$key]);
diff --git a/modules/book/book.module b/modules/book/book.module
index beb1721..17037ea 100644
--- a/modules/book/book.module
+++ b/modules/book/book.module
@@ -1112,12 +1112,12 @@ function book_toc($bid, $depth_limit, $exclude = array()) {
  * @see book-export-html.tpl.php
  */
 function template_preprocess_book_export_html(&$variables) {
-  global $base_url, $language;
+  global $base_url, $language_interface;
 
   $variables['title'] = check_plain($variables['title']);
   $variables['base_url'] = $base_url;
-  $variables['language'] = $language;
-  $variables['language_rtl'] = ($language->direction == LANGUAGE_RTL);
+  $variables['language'] = $language_interface;
+  $variables['language_rtl'] = ($language_interface->direction == LANGUAGE_RTL);
   $variables['head'] = drupal_get_html_head();
 }
 
diff --git a/modules/comment/comment.test b/modules/comment/comment.test
index c9478f4..daf0d7b 100644
--- a/modules/comment/comment.test
+++ b/modules/comment/comment.test
@@ -1,7 +1,7 @@
 <?php
 
 /**
- * @file 
+ * @file
  * Tests for comment.module.
  */
 
@@ -1718,10 +1718,10 @@ class CommentTokenReplaceTestCase extends CommentHelperCase {
    * Creates a comment, then tests the tokens generated from it.
    */
   function testCommentTokenReplacement() {
-    global $language;
+    global $language_interface;
     $url_options = array(
       'absolute' => TRUE,
-      'language' => $language,
+      'language' => $language_interface,
     );
 
     $this->drupalLogin($this->admin_user);
@@ -1754,8 +1754,8 @@ class CommentTokenReplaceTestCase extends CommentHelperCase {
     $tests['[comment:body]'] = _text_sanitize($instance, LANGUAGE_NONE, $comment->comment_body[LANGUAGE_NONE][0], 'value');
     $tests['[comment:url]'] = url('comment/' . $comment->cid, $url_options + array('fragment' => 'comment-' . $comment->cid));
     $tests['[comment:edit-url]'] = url('comment/' . $comment->cid . '/edit', $url_options);
-    $tests['[comment:created:since]'] = format_interval(REQUEST_TIME - $comment->created, 2, $language->language);
-    $tests['[comment:changed:since]'] = format_interval(REQUEST_TIME - $comment->changed, 2, $language->language);
+    $tests['[comment:created:since]'] = format_interval(REQUEST_TIME - $comment->created, 2, $language_interface->language);
+    $tests['[comment:changed:since]'] = format_interval(REQUEST_TIME - $comment->changed, 2, $language_interface->language);
     $tests['[comment:parent:cid]'] = $comment->pid;
     $tests['[comment:parent:title]'] = check_plain($parent_comment->subject);
     $tests['[comment:node:nid]'] = $comment->nid;
@@ -1767,7 +1767,7 @@ class CommentTokenReplaceTestCase extends CommentHelperCase {
     $this->assertFalse(in_array(0, array_map('strlen', $tests)), t('No empty tokens generated.'));
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('comment' => $comment), array('language' => $language));
+      $output = token_replace($input, array('comment' => $comment), array('language' => $language_interface));
       $this->assertEqual($output, $expected, t('Sanitized comment token %token replaced.', array('%token' => $input)));
     }
 
@@ -1783,7 +1783,7 @@ class CommentTokenReplaceTestCase extends CommentHelperCase {
     $tests['[comment:author:name]'] = $this->admin_user->name;
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('comment' => $comment), array('language' => $language, 'sanitize' => FALSE));
+      $output = token_replace($input, array('comment' => $comment), array('language' => $language_interface, 'sanitize' => FALSE));
       $this->assertEqual($output, $expected, t('Unsanitized comment token %token replaced.', array('%token' => $input)));
     }
 
@@ -1796,7 +1796,7 @@ class CommentTokenReplaceTestCase extends CommentHelperCase {
     $tests['[node:comment-count-new]'] = 2;
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('node' => $node), array('language' => $language));
+      $output = token_replace($input, array('node' => $node), array('language' => $language_interface));
       $this->assertEqual($output, $expected, t('Node comment token %token replaced.', array('%token' => $input)));
     }
   }
diff --git a/modules/contact/contact.pages.inc b/modules/contact/contact.pages.inc
index 30b2825..dc727c6 100644
--- a/modules/contact/contact.pages.inc
+++ b/modules/contact/contact.pages.inc
@@ -126,7 +126,7 @@ function contact_site_form_validate($form, &$form_state) {
  * Form submission handler for contact_site_form().
  */
 function contact_site_form_submit($form, &$form_state) {
-  global $user, $language;
+  global $user, $language_interface;
 
   $values = $form_state['values'];
   $values['sender'] = $user;
@@ -148,12 +148,12 @@ function contact_site_form_submit($form, &$form_state) {
 
   // If the user requests it, send a copy using the current language.
   if ($values['copy']) {
-    drupal_mail('contact', 'page_copy', $from, $language, $values, $from);
+    drupal_mail('contact', 'page_copy', $from, $language_interface, $values, $from);
   }
 
   // Send an auto-reply if necessary using the current language.
   if ($values['category']['reply']) {
-    drupal_mail('contact', 'page_autoreply', $from, $language, $values, $to);
+    drupal_mail('contact', 'page_autoreply', $from, $language_interface, $values, $to);
   }
 
   flood_register_event('contact', variable_get('contact_threshold_window', 3600));
@@ -258,7 +258,7 @@ function contact_personal_form_validate($form, &$form_state) {
  * @see contact_personal_form()
  */
 function contact_personal_form_submit($form, &$form_state) {
-  global $user, $language;
+  global $user, $language_interface;
 
   $values = $form_state['values'];
   $values['sender'] = $user;
@@ -279,7 +279,7 @@ function contact_personal_form_submit($form, &$form_state) {
 
   // Send a copy if requested, using current page language.
   if ($values['copy']) {
-    drupal_mail('contact', 'user_copy', $from, $language, $values, $from);
+    drupal_mail('contact', 'user_copy', $from, $language_interface, $values, $from);
   }
 
   flood_register_event('contact', variable_get('contact_threshold_window', 3600));
diff --git a/modules/field/field.info.inc b/modules/field/field.info.inc
index 6b172dd..3b574ba 100644
--- a/modules/field/field.info.inc
+++ b/modules/field/field.info.inc
@@ -66,12 +66,12 @@ function field_info_cache_clear() {
  *     as well as module, giving the module that exposes the entity type.
  */
 function _field_info_collate_types($reset = FALSE) {
-  global $language;
+  global $language_interface;
   static $info;
 
   // The _info() hooks invoked below include translated strings, so each
   // language is cached separately.
-  $langcode = $language->language;
+  $langcode = $language_interface->language;
 
   if ($reset) {
     $info = NULL;
diff --git a/modules/file/tests/file.test b/modules/file/tests/file.test
index 32de9dc..7e6ac11 100644
--- a/modules/file/tests/file.test
+++ b/modules/file/tests/file.test
@@ -996,10 +996,10 @@ class FileTokenReplaceTestCase extends FileFieldTestCase {
    * Creates a file, then tests the tokens generated from it.
    */
   function testFileTokenReplacement() {
-    global $language;
+    global $language_interface;
     $url_options = array(
       'absolute' => TRUE,
-      'language' => $language,
+      'language' => $language_interface,
     );
 
     // Create file field.
@@ -1026,8 +1026,8 @@ class FileTokenReplaceTestCase extends FileFieldTestCase {
     $tests['[file:mime]'] = check_plain($file->filemime);
     $tests['[file:size]'] = format_size($file->filesize);
     $tests['[file:url]'] = check_plain(file_create_url($file->uri));
-    $tests['[file:timestamp]'] = format_date($file->timestamp, 'medium', '', NULL, $language->language);
-    $tests['[file:timestamp:short]'] = format_date($file->timestamp, 'short', '', NULL, $language->language);
+    $tests['[file:timestamp]'] = format_date($file->timestamp, 'medium', '', NULL, $language_interface->language);
+    $tests['[file:timestamp:short]'] = format_date($file->timestamp, 'short', '', NULL, $language_interface->language);
     $tests['[file:owner]'] = check_plain(format_username($this->admin_user));
     $tests['[file:owner:uid]'] = $file->uid;
 
@@ -1035,7 +1035,7 @@ class FileTokenReplaceTestCase extends FileFieldTestCase {
     $this->assertFalse(in_array(0, array_map('strlen', $tests)), t('No empty tokens generated.'));
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('file' => $file), array('language' => $language));
+      $output = token_replace($input, array('file' => $file), array('language' => $language_interface));
       $this->assertEqual($output, $expected, t('Sanitized file token %token replaced.', array('%token' => $input)));
     }
 
@@ -1046,7 +1046,7 @@ class FileTokenReplaceTestCase extends FileFieldTestCase {
     $tests['[file:size]'] = format_size($file->filesize);
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('file' => $file), array('language' => $language, 'sanitize' => FALSE));
+      $output = token_replace($input, array('file' => $file), array('language' => $language_interface, 'sanitize' => FALSE));
       $this->assertEqual($output, $expected, t('Unsanitized file token %token replaced.', array('%token' => $input)));
     }
   }
diff --git a/modules/filter/filter.module b/modules/filter/filter.module
index 27ae02c..55d4bd3 100644
--- a/modules/filter/filter.module
+++ b/modules/filter/filter.module
@@ -390,12 +390,12 @@ function filter_modules_disabled($modules) {
  * @see filter_formats_reset()
  */
 function filter_formats($account = NULL) {
-  global $language;
+  global $language_interface;
   $formats = &drupal_static(__FUNCTION__, array());
 
   // All available formats are cached for performance.
   if (!isset($formats['all'])) {
-    if ($cache = cache_get("filter_formats:{$language->language}")) {
+    if ($cache = cache_get("filter_formats:{$language_interface->language}")) {
       $formats['all'] = $cache->data;
     }
     else {
@@ -407,7 +407,7 @@ function filter_formats($account = NULL) {
         ->execute()
         ->fetchAllAssoc('format');
 
-      cache_set("filter_formats:{$language->language}", $formats['all']);
+      cache_set("filter_formats:{$language_interface->language}", $formats['all']);
     }
   }
 
diff --git a/modules/image/image.module b/modules/image/image.module
index 008a365..b109b5f 100644
--- a/modules/image/image.module
+++ b/modules/image/image.module
@@ -943,11 +943,11 @@ function image_default_style_revert($style) {
  * @see image_effect_definition_load()
  */
 function image_effect_definitions() {
-  global $language;
+  global $language_interface;
 
   // hook_image_effect_info() includes translated strings, so each language is
   // cached separately.
-  $langcode = $language->language;
+  $langcode = $language_interface->language;
 
   $effects = &drupal_static(__FUNCTION__);
 
diff --git a/modules/locale/locale.api.php b/modules/locale/locale.api.php
index 2808f33..bd11764 100644
--- a/modules/locale/locale.api.php
+++ b/modules/locale/locale.api.php
@@ -37,9 +37,9 @@ function hook_locale($op = 'groups') {
  * did not happen yet and thus they cannot rely on translated variables.
  */
 function hook_language_init() {
-  global $language, $conf;
+  global $language_interface, $conf;
 
-  switch ($language->language) {
+  switch ($language_interface->language) {
     case 'it':
       $conf['site_name'] = 'Il mio sito Drupal';
       break;
@@ -65,10 +65,10 @@ function hook_language_init() {
  *   The current path.
  */
 function hook_language_switch_links_alter(array &$links, $type, $path) {
-  global $language;
+  global $language_interface;
 
-  if ($type == LANGUAGE_TYPE_CONTENT && isset($links[$language->language])) {
-    foreach ($links[$language->language] as $link) {
+  if ($type == LANGUAGE_TYPE_CONTENT && isset($links[$language_interface->language])) {
+    foreach ($links[$language_interface->language] as $link) {
       $link['attributes']['class'][] = 'active-language';
     }
   }
diff --git a/modules/locale/locale.install b/modules/locale/locale.install
index a144813..12d5968 100644
--- a/modules/locale/locale.install
+++ b/modules/locale/locale.install
@@ -262,3 +262,33 @@ function locale_schema() {
 
   return $schema;
 }
+
+/**
+ * Language type 'language' renamed to 'language_interface'.
+ */
+function locale_update_7000() {
+  // Only change language_types if we had this setting saved. Keep order
+  // of types because that is significant for value dependency.
+  $types = variable_get('language_types', NULL);
+  if (!empty($types) && isset($types['lanuguage'])) {
+    $new_types = array();
+    foreach ($types as $key => $type) {
+      $new_types[$key == 'language' ? 'language_interface' : $key] = $type;
+    }
+    variable_set('language_types', $new_types);
+  }
+
+  // Rename language_negotiation_language setting if exists.
+  $setting = variable_get('language_negotiation_language', NULL);
+  if ($setting !== NULL) {
+    variable_set('language_negotiation_language_interface', $setting);
+    variable_del('language_negotiation_language');
+  }
+
+  // Rename locale_language_providers_weight_language setting if exists.
+  $weight = variable_get('locale_language_providers_weight_language', NULL);
+  if ($weight !== NULL) {
+    variable_set('locale_language_providers_weight_language_interface', $weight);
+    variable_del('locale_language_providers_weight_language');
+  }
+}
diff --git a/modules/locale/locale.module b/modules/locale/locale.module
index 871048b..c6030fa 100644
--- a/modules/locale/locale.module
+++ b/modules/locale/locale.module
@@ -224,7 +224,7 @@ function locale_menu() {
  * Initialize date formats according to the user's current locale.
  */
 function locale_init() {
-  global $conf, $language;
+  global $conf, $language_interface;
   include_once DRUPAL_ROOT . '/includes/locale.inc';
 
   // For each date type (e.g. long, short), get the localized date format
@@ -233,7 +233,7 @@ function locale_init() {
   // settings page, where we want to display the site default and not the
   // localized version.
   if (strpos($_GET['q'], 'admin/config/regional/date-time/formats') !== 0) {
-    $languages = array($language->language);
+    $languages = array($language_interface->language);
 
     // Setup appropriate date formats for this locale.
     $formats = locale_get_localized_date_format($languages);
@@ -274,12 +274,12 @@ function locale_locale($op = 'groups') {
  * @see locale_form_alter()
  */
 function locale_language_selector_form(&$form, &$form_state, $user) {
-  global $language;
+  global $language_interface;
   $languages = language_list('enabled');
   $languages = $languages[1];
 
   // If the user is being created, we set the user language to the page language.
-  $user_preferred_language = $user->uid ? user_preferred_language($user) : $language;
+  $user_preferred_language = $user->uid ? user_preferred_language($user) : $language_interface;
 
   $names = array();
   foreach ($languages as $langcode => $item) {
@@ -629,7 +629,7 @@ function locale_modules_disabled($modules) {
  *   Language code to use for the lookup.
  */
 function locale($string = NULL, $context = NULL, $langcode = NULL) {
-  global $language;
+  global $language_interface;
   $locale_t = &drupal_static(__FUNCTION__);
 
   if (!isset($string)) {
@@ -637,11 +637,12 @@ function locale($string = NULL, $context = NULL, $langcode = NULL) {
     return $locale_t;
   }
 
-  $langcode = isset($langcode) ? $langcode : $language->language;
+  $langcode = isset($langcode) ? $langcode : $language_interface->language;
 
   // Store database cached translations in a static variable. Only build the
-  // cache after $language has been set to avoid an unnecessary cache rebuild.
-  if (!isset($locale_t[$langcode]) && isset($language)) {
+  // cache after $language_interface has been set to avoid an unnecessary cache
+  // rebuild.
+  if (!isset($locale_t[$langcode]) && isset($language_interface)) {
     $locale_t[$langcode] = array();
     // Disabling the usage of string caching allows a module to watch for
     // the exact list of strings used on a page. From a performance
@@ -729,11 +730,11 @@ function locale_reset() {
  *   what is used to display the page.
  */
 function locale_get_plural($count, $langcode = NULL) {
-  global $language;
+  global $language_interface;
   $locale_formula = &drupal_static(__FUNCTION__, array());
   $plurals = &drupal_static(__FUNCTION__ . ':plurals', array());
 
-  $langcode = $langcode ? $langcode : $language->language;
+  $langcode = $langcode ? $langcode : $language_interface->language;
 
   if (!isset($plurals[$langcode][$count])) {
     if (empty($locale_formula)) {
@@ -832,7 +833,7 @@ function locale_system_update($components) {
  * file if necessary, and adds it to the page.
  */
 function locale_js_alter(&$javascript) {
-  global $language;
+  global $language_interface;
 
   $dir = 'public://' . variable_get('locale_js_directory', 'languages');
   $parsed = variable_get('javascript_parsed', array());
@@ -864,11 +865,11 @@ function locale_js_alter(&$javascript) {
   }
 
   // If necessary, rebuild the translation file for the current language.
-  if (!empty($parsed['refresh:' . $language->language])) {
+  if (!empty($parsed['refresh:' . $language_interface->language])) {
     // Don't clear the refresh flag on failure, so that another try will
     // be performed later.
     if (_locale_rebuild_js()) {
-      unset($parsed['refresh:' . $language->language]);
+      unset($parsed['refresh:' . $language_interface->language]);
     }
     // Store any changes after refresh was attempted.
     variable_set('javascript_parsed', $parsed);
@@ -880,9 +881,9 @@ function locale_js_alter(&$javascript) {
   }
 
   // Add the translation JavaScript file to the page.
-  if ($files && !empty($language->javascript)) {
+  if ($files && !empty($language_interface->javascript)) {
     // Add the translation JavaScript file to the page.
-    $file = $dir . '/' . $language->language . '_' . $language->javascript . '.js';
+    $file = $dir . '/' . $language_interface->language . '_' . $language_interface->javascript . '.js';
     $javascript[$file] = drupal_js_defaults($file);
   }
 }
@@ -894,10 +895,10 @@ function locale_js_alter(&$javascript) {
  * and checks to see if a related right to left CSS file should be included.
  */
 function locale_css_alter(&$css) {
-  global $language;
+  global $language_interface;
 
   // If the current language is RTL, add the CSS file with the RTL overrides.
-  if ($language->direction == LANGUAGE_RTL) {
+  if ($language_interface->direction == LANGUAGE_RTL) {
     foreach ($css as $data => $item) {
       // Only provide RTL overrides for files.
       if ($item['type'] == 'file') {
@@ -920,14 +921,14 @@ function locale_css_alter(&$css) {
  * Provides the language support for the jQuery UI Date Picker.
  */
 function locale_library_alter(&$libraries, $module) {
-  global $language;
+  global $language_interface;
   if ($module == 'system' && isset($libraries['system']['ui.datepicker'])) {
     $datepicker = drupal_get_path('module', 'locale') . '/locale.datepicker.js';
     $libraries['system']['ui.datepicker']['js'][$datepicker] = array('group' => JS_THEME);
     $libraries['system']['ui.datepicker']['js'][] = array(
       'data' => array(
         'jqueryuidatepicker' => array(
-          'rtl' => $language->direction == LANGUAGE_RTL,
+          'rtl' => $language_interface->direction == LANGUAGE_RTL,
           'firstDay' => variable_get('date_first_day', 0),
         ),
       ),
diff --git a/modules/locale/locale.test b/modules/locale/locale.test
index 3ae6d91..684ed9e 100644
--- a/modules/locale/locale.test
+++ b/modules/locale/locale.test
@@ -1131,8 +1131,8 @@ class LocaleUninstallFunctionalTest extends DrupalWebTestCase {
 
     // Check the UI language.
     drupal_language_initialize();
-    global $language;
-    $this->assertEqual($language->language, $this->language, t('Current language: %lang', array('%lang' => $language->language)));
+    global $language_interface;
+    $this->assertEqual($language_interface->language, $this->language, t('Current language: %lang', array('%lang' => $language_interface->language)));
 
     // Enable multilingual workflow option for articles.
     variable_set('language_content_type_article', 1);
@@ -1178,7 +1178,7 @@ class LocaleUninstallFunctionalTest extends DrupalWebTestCase {
 
     // Check the init language logic.
     drupal_language_initialize();
-    $this->assertEqual($language->language, 'en', t('Language after uninstall: %lang', array('%lang' => $language->language)));
+    $this->assertEqual($language_interface->language, 'en', t('Language after uninstall: %lang', array('%lang' => $language_interface->language)));
 
     // Check JavaScript files deletion.
     $this->assertTrue($result = !file_exists($js_file), t('JavaScript file deleted: %file', array('%file' => $result ? $js_file : t('found'))));
@@ -1282,7 +1282,7 @@ class LocaleLanguageSwitchingFunctionalTest extends DrupalWebTestCase {
     $this->drupalPost('admin/config/regional/language/add', $edit, t('Add language'));
 
     // Enable URL language detection and selection.
-    $edit = array('language[enabled][locale-url]' => '1');
+    $edit = array('language_interface[enabled][locale-url]' => '1');
     $this->drupalPost('admin/config/regional/language/configure', $edit, t('Save settings'));
 
     // Assert that the language switching block is displayed on the frontpage.
@@ -1290,7 +1290,7 @@ class LocaleLanguageSwitchingFunctionalTest extends DrupalWebTestCase {
     $this->assertText(t('Languages'), t('Language switcher block found.'));
 
     // Assert that only the current language is marked as active.
-    list($language_switcher) = $this->xpath('//div[@id=:id]/div[@class="content"]', array(':id' => 'block-locale-' . $language_type));
+    list($language_switcher) = $this->xpath('//div[@id=:id]/div[@class="content"]', array(':id' => 'block-locale-' . str_replace('_', '-', $language_type)));
     $links = array(
       'active' => array(),
       'inactive' => array(),
@@ -1453,7 +1453,7 @@ class LocaleUserCreationTest extends DrupalWebTestCase {
 
     // Set language negotiation.
     $edit = array(
-      'language[enabled][locale-url]' => TRUE,
+      'language_interface[enabled][locale-url]' => TRUE,
     );
     $this->drupalPost('admin/config/regional/language/configure', $edit, t('Save settings'));
     $this->assertText(t('Language negotiation configuration saved.'), t('Set language negotiation.'));
@@ -1569,7 +1569,7 @@ class LocalePathFunctionalTest extends DrupalWebTestCase {
     $this->assertResponse(404, t('The "xx" front page is not available yet.'));
 
     // Enable URL language detection and selection.
-    $edit = array('language[enabled][locale-url]' => 1);
+    $edit = array('language_interface[enabled][locale-url]' => 1);
     $this->drupalPost('admin/config/regional/language/configure', $edit, t('Save settings'));
 
     // Create a node.
@@ -1994,16 +1994,16 @@ class LocaleUILanguageNegotiationTest extends DrupalWebTestCase {
 
     // Enable browser and URL language detection.
     $edit = array(
-      'language[enabled][locale-browser]' => TRUE,
-      'language[enabled][locale-url]' => TRUE,
-      'language[weight][locale-browser]' => -8,
-      'language[weight][locale-url]' => -10,
+      'language_interface[enabled][locale-browser]' => TRUE,
+      'language_interface[enabled][locale-url]' => TRUE,
+      'language_interface[weight][locale-browser]' => -8,
+      'language_interface[weight][locale-url]' => -10,
     );
     $this->drupalPost('admin/config/regional/language/configure', $edit, t('Save settings'));
     $this->drupalGet('admin/config/regional/language/configure');
 
     // Enable the language switcher block.
-    $edit = array('blocks[locale_language][region]' => 'sidebar_first');
+    $edit = array('blocks[locale_language_interface][region]' => 'sidebar_first');
     $this->drupalPost('admin/structure/block', $edit, t('Save blocks'));
 
     // Access the front page without specifying any valid URL language prefix
@@ -2014,7 +2014,7 @@ class LocaleUILanguageNegotiationTest extends DrupalWebTestCase {
     // Check that the language switcher active link matches the given browser
     // language.
     $args = array(':url' => base_path() . (!empty($GLOBALS['conf']['clean_url']) ? $language_browser_fallback : "?q=$language_browser_fallback"));
-    $fields = $this->xpath('//div[@id="block-locale-language"]//a[@class="language-link active" and @href=:url]', $args);
+    $fields = $this->xpath('//div[@id="block-locale-language-interface"]//a[@class="language-link active" and @href=:url]', $args);
     $this->assertTrue($fields[0] == $languages[$language_browser_fallback]->native, t('The browser language is the URL active language'));
 
     // Check that URLs are rewritten using the given browser language.
@@ -2057,7 +2057,7 @@ class LocaleUrlRewritingTest extends DrupalWebTestCase {
     $this->drupalPost('admin/config/regional/language', $edit, t('Save configuration'));
 
     // Enable URL language detection and selection.
-    $edit = array('language[enabled][locale-url]' => 1);
+    $edit = array('language_interface[enabled][locale-url]' => 1);
     $this->drupalPost('admin/config/regional/language/configure', $edit, t('Save settings'));
 
     // Reset static caching.
@@ -2128,7 +2128,7 @@ class LocaleMultilingualFieldsFunctionalTest extends DrupalWebTestCase {
     locale_add_language('it', 'Italian', 'Italiano', LANGUAGE_LTR, '', '', TRUE, FALSE);
 
     // Enable URL language detection and selection.
-    $edit = array('language[enabled][locale-url]' => '1');
+    $edit = array('language_interface[enabled][locale-url]' => '1');
     $this->drupalPost('admin/config/regional/language/configure', $edit, t('Save settings'));
 
     // Set "Basic page" content type to use multilingual support.
@@ -2258,7 +2258,7 @@ class LocaleCommentLanguageFunctionalTest extends DrupalWebTestCase {
     // language will fall back to the default language if no URL language can be
     // detected.
     $edit = array(
-      'language[enabled][locale-user]' => TRUE,
+      'language_interface[enabled][locale-user]' => TRUE,
       'language_content[enabled][locale-url]' => TRUE,
       'language_content[enabled][locale-interface]' => FALSE,
     );
diff --git a/modules/node/node.module b/modules/node/node.module
index 7956bff..10a1991 100644
--- a/modules/node/node.module
+++ b/modules/node/node.module
@@ -668,7 +668,7 @@ function node_type_update_nodes($old_type, $type) {
  *   type object by $type->disabled being set to TRUE.
  */
 function _node_types_build($rebuild = FALSE) {
-  $cid = 'node_types:' . $GLOBALS['language']->language;
+  $cid = 'node_types:' . $GLOBALS['language_interface']->language;
 
   if (!$rebuild) {
     $_node_types = &drupal_static(__FUNCTION__);
diff --git a/modules/node/node.test b/modules/node/node.test
index 56a2d34..d8493ba 100644
--- a/modules/node/node.test
+++ b/modules/node/node.test
@@ -2237,10 +2237,10 @@ class NodeTokenReplaceTestCase extends DrupalWebTestCase {
    * Creates a node, then tests the tokens generated from it.
    */
   function testNodeTokenReplacement() {
-    global $language;
+    global $language_interface;
     $url_options = array(
       'absolute' => TRUE,
-      'language' => $language,
+      'language' => $language_interface,
     );
 
     // Create a user and a node.
@@ -2272,14 +2272,14 @@ class NodeTokenReplaceTestCase extends DrupalWebTestCase {
     $tests['[node:edit-url]'] = url('node/' . $node->nid . '/edit', $url_options);
     $tests['[node:author:uid]'] = $node->uid;
     $tests['[node:author:name]'] = check_plain(format_username($account));
-    $tests['[node:created:since]'] = format_interval(REQUEST_TIME - $node->created, 2, $language->language);
-    $tests['[node:changed:since]'] = format_interval(REQUEST_TIME - $node->changed, 2, $language->language);
+    $tests['[node:created:since]'] = format_interval(REQUEST_TIME - $node->created, 2, $language_interface->language);
+    $tests['[node:changed:since]'] = format_interval(REQUEST_TIME - $node->changed, 2, $language_interface->language);
 
     // Test to make sure that we generated something for each token.
     $this->assertFalse(in_array(0, array_map('strlen', $tests)), t('No empty tokens generated.'));
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('node' => $node), array('language' => $language));
+      $output = token_replace($input, array('node' => $node), array('language' => $language_interface));
       $this->assertEqual($output, $expected, t('Sanitized node token %token replaced.', array('%token' => $input)));
     }
 
@@ -2291,7 +2291,7 @@ class NodeTokenReplaceTestCase extends DrupalWebTestCase {
     $tests['[node:author:name]'] = format_username($account);
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('node' => $node), array('language' => $language, 'sanitize' => FALSE));
+      $output = token_replace($input, array('node' => $node), array('language' => $language_interface, 'sanitize' => FALSE));
       $this->assertEqual($output, $expected, t('Unsanitized node token %token replaced.', array('%token' => $input)));
     }
   }
diff --git a/modules/openid/openid.inc b/modules/openid/openid.inc
index 6945f34..27203d0 100644
--- a/modules/openid/openid.inc
+++ b/modules/openid/openid.inc
@@ -88,10 +88,10 @@ function openid_redirect_http($url, $message) {
  * Creates a js auto-submit redirect for (for the 2.x protocol)
  */
 function openid_redirect($url, $message) {
-  global $language;
-  
+  global $language_interface;
+
   $output = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">' . "\n";
-  $output .= '<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="' . $language->language . '" lang="' . $language->language . '">' . "\n";
+  $output .= '<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="' . $language_interface->language . '" lang="' . $language_interface->language . '">' . "\n";
   $output .= "<head>\n";
   $output .= "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n";
   $output .= "<title>" . t('OpenID redirect') . "</title>\n";
diff --git a/modules/path/path.test b/modules/path/path.test
index f42ec81..6ea47af 100644
--- a/modules/path/path.test
+++ b/modules/path/path.test
@@ -251,7 +251,7 @@ class PathLanguageTestCase extends DrupalWebTestCase {
     $this->drupalPost('admin/config/regional/language/add', $edit, t('Add language'));
 
     // Enable URL language detection and selection.
-    $edit = array('language[enabled][locale-url]' => 1);
+    $edit = array('language_interface[enabled][locale-url]' => 1);
     $this->drupalPost('admin/config/regional/language/configure', $edit, t('Save settings'));
   }
 
@@ -307,10 +307,10 @@ class PathLanguageTestCase extends DrupalWebTestCase {
     // Confirm that the alias works even when changing language negotiation
     // options. Enable User language detection and selection over URL one.
     $edit = array(
-      'language[enabled][locale-user]' => 1,
-      'language[weight][locale-user]' => -9,
-      'language[enabled][locale-url]' => 1,
-      'language[weight][locale-url]' => -8,
+      'language_interface[enabled][locale-user]' => 1,
+      'language_interface[weight][locale-user]' => -9,
+      'language_interface[enabled][locale-url]' => 1,
+      'language_interface[weight][locale-url]' => -8,
     );
     $this->drupalPost('admin/config/regional/language/configure', $edit, t('Save settings'));
 
@@ -334,7 +334,7 @@ class PathLanguageTestCase extends DrupalWebTestCase {
     $this->assertText($french_node->title, 'Alias for French translation works.');
 
     // Disable URL language negotiation.
-    $edit = array('language[enabled][locale-url]' => FALSE);
+    $edit = array('language_interface[enabled][locale-url]' => FALSE);
     $this->drupalPost('admin/config/regional/language/configure', $edit, t('Save settings'));
 
     // Check that the English alias still works.
@@ -392,7 +392,7 @@ class PathLanguageUITestCase extends DrupalWebTestCase {
     $this->drupalPost('admin/config/regional/language/add', $edit, t('Add language'));
 
     // Enable URL language detection and selection.
-    $edit = array('language[enabled][locale-url]' => 1);
+    $edit = array('language_interface[enabled][locale-url]' => 1);
     $this->drupalPost('admin/config/regional/language/configure', $edit, t('Save settings'));
   }
 
@@ -455,7 +455,6 @@ class PathMonolingualTestCase extends DrupalWebTestCase {
   }
 
   function setUp() {
-    global $language;
     parent::setUp('path', 'locale', 'translation');
 
     // Create and login user.
@@ -480,7 +479,7 @@ class PathMonolingualTestCase extends DrupalWebTestCase {
     $this->assertEqual(language_default('language'), 'fr', t('French is the default language'));
 
     // Set language detection to URL.
-    $edit = array('language[enabled][locale-url]' => TRUE);
+    $edit = array('language_interface[enabled][locale-url]' => TRUE);
     $this->drupalPost('admin/config/regional/language/configure', $edit, t('Save settings'));
 
     // Force languages to be initialized.
diff --git a/modules/poll/poll.test b/modules/poll/poll.test
index 6fabf95..f59f7cf 100644
--- a/modules/poll/poll.test
+++ b/modules/poll/poll.test
@@ -596,7 +596,7 @@ class PollTokenReplaceTestCase extends PollTestCase {
    * Creates a poll, then tests the tokens generated from it.
    */
   function testPollTokenReplacement() {
-    global $language;
+    global $language_interface;
 
     // Craete a poll with three choices.
     $title = $this->randomName();
@@ -645,13 +645,13 @@ class PollTokenReplaceTestCase extends PollTestCase {
     $tests['[node:poll-winner]'] = filter_xss($poll->choice[1]['chtext']);
     $tests['[node:poll-winner-votes]'] = 2;
     $tests['[node:poll-winner-percent]'] = 50;
-    $tests['[node:poll-duration]'] = format_interval($poll->runtime, 1, $language->language);
+    $tests['[node:poll-duration]'] = format_interval($poll->runtime, 1, $language_interface->language);
 
     // Test to make sure that we generated something for each token.
     $this->assertFalse(in_array(0, array_map('strlen', $tests)), t('No empty tokens generated.'));
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('node' => $poll), array('language' => $language));
+      $output = token_replace($input, array('node' => $poll), array('language' => $language_interface));
       $this->assertEqual($output, $expected, t('Sanitized poll token %token replaced.', array('%token' => $input)));
     }
 
@@ -659,7 +659,7 @@ class PollTokenReplaceTestCase extends PollTestCase {
     $tests['[node:poll-winner]'] = $poll->choice[1]['chtext'];
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('node' => $poll), array('language' => $language, 'sanitize' => FALSE));
+      $output = token_replace($input, array('node' => $poll), array('language' => $language_interface, 'sanitize' => FALSE));
       $this->assertEqual($output, $expected, t('Unsanitized poll token %token replaced.', array('%token' => $input)));
     }
   }
diff --git a/modules/search/search.pages.inc b/modules/search/search.pages.inc
index 833ea8b..0dcb37b 100644
--- a/modules/search/search.pages.inc
+++ b/modules/search/search.pages.inc
@@ -104,12 +104,12 @@ function template_preprocess_search_results(&$variables) {
  * @see search-result.tpl.php
  */
 function template_preprocess_search_result(&$variables) {
-  global $language;
+  global $language_interface;
 
   $result = $variables['result'];
   $variables['url'] = check_url($result['link']);
   $variables['title'] = check_plain($result['title']);
-  if (isset($result['language']) && $result['language'] != $language->language && $result['language'] != LANGUAGE_NONE) {
+  if (isset($result['language']) && $result['language'] != $language_interface->language && $result['language'] != LANGUAGE_NONE) {
     $variables['title_attributes_array']['xml:lang'] = $result['language'];
     $variables['content_attributes_array']['xml:lang'] = $result['language'];
   }
diff --git a/modules/simpletest/drupal_web_test_case.php b/modules/simpletest/drupal_web_test_case.php
index 5c39cfc..118d9ab 100644
--- a/modules/simpletest/drupal_web_test_case.php
+++ b/modules/simpletest/drupal_web_test_case.php
@@ -1229,7 +1229,7 @@ class DrupalWebTestCase extends DrupalTestCase {
    *   either a single array or a variable number of string arguments.
    */
   protected function setUp() {
-    global $user, $language, $conf;
+    global $user, $language_interface, $conf;
 
     // Generate a temporary prefixed database to ensure that tests have a clean starting point.
     $this->databasePrefix = 'simpletest' . mt_rand(1000, 1000000);
@@ -1249,7 +1249,7 @@ class DrupalWebTestCase extends DrupalTestCase {
     Database::addConnectionInfo('default', 'default', $connection_info['default']);
 
     // Store necessary current values before switching to prefixed database.
-    $this->originalLanguage = $language;
+    $this->originalLanguage = $language_interface;
     $this->originalLanguageDefault = variable_get('language_default');
     $this->originalFileDirectory = variable_get('file_public_path', conf_path() . '/files');
     $this->originalProfile = drupal_get_profile();
@@ -1351,7 +1351,7 @@ class DrupalWebTestCase extends DrupalTestCase {
     variable_set('date_default_timezone', date_default_timezone_get());
     // Set up English language.
     unset($GLOBALS['conf']['language_default']);
-    $language = language_default();
+    $language_interface = language_default();
 
     // Use the test mail class instead of the default mail handler class.
     variable_set('mail_system', array('default-system' => 'TestingMailSystem'));
@@ -1444,7 +1444,7 @@ class DrupalWebTestCase extends DrupalTestCase {
    * and reset the database prefix.
    */
   protected function tearDown() {
-    global $user, $language;
+    global $user, $language_interface;
 
     // In case a fatal error occured that was not in the test process read the
     // log to pick up any fatal errors.
@@ -1494,7 +1494,7 @@ class DrupalWebTestCase extends DrupalTestCase {
     $this->refreshVariables();
 
     // Reset language.
-    $language = $this->originalLanguage;
+    $language_interface = $this->originalLanguage;
     if ($this->originalLanguageDefault) {
       $GLOBALS['conf']['language_default'] = $this->originalLanguageDefault;
     }
diff --git a/modules/simpletest/tests/common.test b/modules/simpletest/tests/common.test
index 177e457..08abfe1 100644
--- a/modules/simpletest/tests/common.test
+++ b/modules/simpletest/tests/common.test
@@ -761,8 +761,8 @@ class CascadingStylesheetsTestCase extends DrupalWebTestCase {
    */
   function testAlter() {
     // Switch the language to a right to left language and add system.base.css.
-    global $language;
-    $language->direction = LANGUAGE_RTL;
+    global $language_interface;
+    $language_interface->direction = LANGUAGE_RTL;
     $path = drupal_get_path('module', 'system');
     drupal_add_css($path . '/system.base.css');
 
@@ -771,7 +771,7 @@ class CascadingStylesheetsTestCase extends DrupalWebTestCase {
     $this->assert(strpos($styles, $path . '/system.base-rtl.css') !== FALSE, t('CSS is alterable as right to left overrides are added.'));
 
     // Change the language back to left to right.
-    $language->direction = LANGUAGE_LTR;
+    $language_interface->direction = LANGUAGE_LTR;
   }
 
   /**
@@ -2199,7 +2199,7 @@ class FormatDateUnitTest extends DrupalWebTestCase {
    * Tests for the format_date() function.
    */
   function testFormatDate() {
-    global $user, $language;
+    global $user, $language_interface;
 
     $timestamp = strtotime('2007-03-26T00:00:00+00:00');
     $this->assertIdentical(format_date($timestamp, 'custom', 'l, d-M-y H:i:s T', 'America/Los_Angeles', 'en'), 'Sunday, 25-Mar-07 17:00:00 PDT', t('Test all parameters.'));
@@ -2232,8 +2232,8 @@ class FormatDateUnitTest extends DrupalWebTestCase {
     // Save the original user and language and then replace it with the test user and language.
     $real_user = $user;
     $user = user_load($test_user->uid, TRUE);
-    $real_language = $language->language;
-    $language->language = $user->language;
+    $real_language = $language_interface->language;
+    $language_interface->language = $user->language;
     // Simulate a Drupal bootstrap with the logged-in user.
     date_default_timezone_set(drupal_get_user_timezone());
 
@@ -2247,7 +2247,7 @@ class FormatDateUnitTest extends DrupalWebTestCase {
 
     // Restore the original user and language, and enable session saving.
     $user = $real_user;
-    $language->language = $real_language;
+    $language_interface->language = $real_language;
     // Restore default time zone.
     date_default_timezone_set(drupal_get_user_timezone());
     drupal_save_session(TRUE);
diff --git a/modules/simpletest/tests/mail.test b/modules/simpletest/tests/mail.test
index a6c7b40..9cde6f2 100644
--- a/modules/simpletest/tests/mail.test
+++ b/modules/simpletest/tests/mail.test
@@ -32,10 +32,10 @@ class MailTestCase extends DrupalWebTestCase implements MailSystemInterface {
    * Assert that the pluggable mail system is functional.
    */
   function testPluggableFramework() {
-    global $language;
+    global $language_interface;
 
     // Use MailTestCase for sending a message.
-    $message = drupal_mail('simpletest', 'mail_test', 'testing@drupal.org', $language);
+    $message = drupal_mail('simpletest', 'mail_test', 'testing@drupal.org', $language_interface);
 
     // Assert whether the message was sent through the send function.
     $this->assertEqual(self::$sent_message['to'], 'testing@drupal.org', t('Pluggable mail system is extendable.'));
diff --git a/modules/simpletest/tests/upgrade/upgrade.test b/modules/simpletest/tests/upgrade/upgrade.test
index 1ef8525..53f644f 100644
--- a/modules/simpletest/tests/upgrade/upgrade.test
+++ b/modules/simpletest/tests/upgrade/upgrade.test
@@ -31,7 +31,7 @@ abstract class UpgradePathTestCase extends DrupalWebTestCase {
    * Override of DrupalWebTestCase::setUp() specialized for upgrade testing.
    */
   protected function setUp() {
-    global $user, $language, $conf;
+    global $user, $language_interface, $conf;
 
     // Load the Update API.
     require_once DRUPAL_ROOT . '/includes/update.inc';
@@ -60,7 +60,7 @@ abstract class UpgradePathTestCase extends DrupalWebTestCase {
     Database::addConnectionInfo('default', 'default', $connection_info['default']);
 
     // Store necessary current values before switching to prefixed database.
-    $this->originalLanguage = $language;
+    $this->originalLanguage = $language_interface;
     $this->originalLanguageDefault = variable_get('language_default');
     $this->originalFileDirectory = variable_get('file_public_path', conf_path() . '/files');
     $this->originalProfile = drupal_get_profile();
@@ -135,7 +135,7 @@ abstract class UpgradePathTestCase extends DrupalWebTestCase {
    * Override of DrupalWebTestCase::tearDown() specialized for upgrade testing.
    */
   protected function tearDown() {
-    global $user, $language;
+    global $user, $language_interface;
 
     // In case a fatal error occured that was not in the test process read the
     // log to pick up any fatal errors.
@@ -174,7 +174,7 @@ abstract class UpgradePathTestCase extends DrupalWebTestCase {
     parent::refreshVariables();
 
     // Reset language.
-    $language = $this->originalLanguage;
+    $language_interface = $this->originalLanguage;
     if ($this->originalLanguageDefault) {
       $GLOBALS['conf']['language_default'] = $this->originalLanguageDefault;
     }
diff --git a/modules/statistics/statistics.test b/modules/statistics/statistics.test
index 126828f..c42daf5 100644
--- a/modules/statistics/statistics.test
+++ b/modules/statistics/statistics.test
@@ -415,7 +415,7 @@ class StatisticsTokenReplaceTestCase extends StatisticsTestCase {
    * Creates a node, then tests the statistics tokens generated from it.
    */
   function testStatisticsTokenReplacement() {
-    global $language;
+    global $language_interface;
 
     // Create user and node.
     $user = $this->drupalCreateUser(array('create page content'));
@@ -437,7 +437,7 @@ class StatisticsTokenReplaceTestCase extends StatisticsTestCase {
     $this->assertFalse(in_array(0, array_map('strlen', $tests)), t('No empty tokens generated.'));
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('node' => $node), array('language' => $language));
+      $output = token_replace($input, array('node' => $node), array('language' => $language_interface));
       $this->assertEqual($output, $expected, t('Statistics token %token replaced.', array('%token' => $input)));
     }
   }
diff --git a/modules/system/system.api.php b/modules/system/system.api.php
index acbc843..b369337 100644
--- a/modules/system/system.api.php
+++ b/modules/system/system.api.php
@@ -2233,7 +2233,7 @@ function hook_xmlrpc_alter(&$methods) {
  *   - message: The text of the message to be logged.
  */
 function hook_watchdog(array $log_entry) {
-  global $base_url, $language;
+  global $base_url, $language_interface;
 
   $severity_list = array(
     WATCHDOG_EMERGENCY     => t('Emergency'),
@@ -2279,7 +2279,7 @@ function hook_watchdog(array $log_entry) {
     '@message'       => strip_tags($log_entry['message']),
   ));
 
-  drupal_mail('emaillog', 'entry', $to, $language, $params);
+  drupal_mail('emaillog', 'entry', $to, $language_interface, $params);
 }
 
 /**
diff --git a/modules/system/system.test b/modules/system/system.test
index 9944619..b19091d 100644
--- a/modules/system/system.test
+++ b/modules/system/system.test
@@ -1812,7 +1812,7 @@ class TokenReplaceTestCase extends DrupalWebTestCase {
     $account = $this->drupalCreateUser();
     $node = $this->drupalCreateNode(array('uid' => $account->uid));
     $node->title = '<blink>Blinking Text</blink>';
-    global $user, $language;
+    global $user, $language_interface;
 
     $source  = '[node:title]';         // Title of the node we passed in
     $source .= '[node:author:name]';   // Node author's name
@@ -1824,18 +1824,18 @@ class TokenReplaceTestCase extends DrupalWebTestCase {
 
     $target  = check_plain($node->title);
     $target .= check_plain($account->name);
-    $target .= format_interval(REQUEST_TIME - $node->created, 2, $language->language);
+    $target .= format_interval(REQUEST_TIME - $node->created, 2, $language_interface->language);
     $target .= check_plain($user->name);
-    $target .= format_date(REQUEST_TIME, 'short', '', NULL, $language->language);
+    $target .= format_date(REQUEST_TIME, 'short', '', NULL, $language_interface->language);
 
     // Test that the clear parameter cleans out non-existent tokens.
-    $result = token_replace($source, array('node' => $node), array('language' => $language, 'clear' => TRUE));
+    $result = token_replace($source, array('node' => $node), array('language' => $language_interface, 'clear' => TRUE));
     $result = $this->assertEqual($target, $result, 'Valid tokens replaced while invalid tokens cleared out.');
 
     // Test without using the clear parameter (non-existant token untouched).
     $target .= '[user:name]';
     $target .= '[bogus:token]';
-    $result = token_replace($source, array('node' => $node), array('language' => $language));
+    $result = token_replace($source, array('node' => $node), array('language' => $language_interface));
     $this->assertEqual($target, $result, 'Valid tokens replaced while invalid tokens ignored.');
 
     // Check that the results of token_generate are sanitized properly. This does NOT
@@ -1854,7 +1854,7 @@ class TokenReplaceTestCase extends DrupalWebTestCase {
    * Test whether token-replacement works in various contexts.
    */
   function testSystemTokenRecognition() {
-    global $language;
+    global $language_interface;
 
     // Generate prefixes and suffixes for the token context.
     $tests = array(
@@ -1874,7 +1874,7 @@ class TokenReplaceTestCase extends DrupalWebTestCase {
     foreach ($tests as $test) {
       $input = $test['prefix'] . '[site:name]' . $test['suffix'];
       $expected = $test['prefix'] . 'Drupal' . $test['suffix'];
-      $output = token_replace($input, array(), array('language' => $language));
+      $output = token_replace($input, array(), array('language' => $language_interface));
       $this->assertTrue($output == $expected, t('Token recognized in string %string', array('%string' => $input)));
     }
   }
@@ -1883,10 +1883,10 @@ class TokenReplaceTestCase extends DrupalWebTestCase {
    * Tests the generation of all system site information tokens.
    */
   function testSystemSiteTokenReplacement() {
-    global $language;
+    global $language_interface;
     $url_options = array(
       'absolute' => TRUE,
-      'language' => $language,
+      'language' => $language_interface,
     );
 
     // Set a few site variables.
@@ -1906,7 +1906,7 @@ class TokenReplaceTestCase extends DrupalWebTestCase {
     $this->assertFalse(in_array(0, array_map('strlen', $tests)), t('No empty tokens generated.'));
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array(), array('language' => $language));
+      $output = token_replace($input, array(), array('language' => $language_interface));
       $this->assertEqual($output, $expected, t('Sanitized system site information token %token replaced.', array('%token' => $input)));
     }
 
@@ -1915,7 +1915,7 @@ class TokenReplaceTestCase extends DrupalWebTestCase {
     $tests['[site:slogan]'] = variable_get('site_slogan', '');
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array(), array('language' => $language, 'sanitize' => FALSE));
+      $output = token_replace($input, array(), array('language' => $language_interface, 'sanitize' => FALSE));
       $this->assertEqual($output, $expected, t('Unsanitized system site information token %token replaced.', array('%token' => $input)));
     }
   }
@@ -1924,25 +1924,25 @@ class TokenReplaceTestCase extends DrupalWebTestCase {
    * Tests the generation of all system date tokens.
    */
   function testSystemDateTokenReplacement() {
-    global $language;
+    global $language_interface;
 
     // Set time to one hour before request.
     $date = REQUEST_TIME - 3600;
 
     // Generate and test tokens.
     $tests = array();
-    $tests['[date:short]'] = format_date($date, 'short', '', NULL, $language->language);
-    $tests['[date:medium]'] = format_date($date, 'medium', '', NULL, $language->language);
-    $tests['[date:long]'] = format_date($date, 'long', '', NULL, $language->language);
-    $tests['[date:custom:m/j/Y]'] = format_date($date, 'custom', 'm/j/Y', NULL, $language->language);
-    $tests['[date:since]'] = format_interval((REQUEST_TIME - $date), 2, $language->language);
+    $tests['[date:short]'] = format_date($date, 'short', '', NULL, $language_interface->language);
+    $tests['[date:medium]'] = format_date($date, 'medium', '', NULL, $language_interface->language);
+    $tests['[date:long]'] = format_date($date, 'long', '', NULL, $language_interface->language);
+    $tests['[date:custom:m/j/Y]'] = format_date($date, 'custom', 'm/j/Y', NULL, $language_interface->language);
+    $tests['[date:since]'] = format_interval((REQUEST_TIME - $date), 2, $language_interface->language);
     $tests['[date:raw]'] = filter_xss($date);
 
     // Test to make sure that we generated something for each token.
     $this->assertFalse(in_array(0, array_map('strlen', $tests)), t('No empty tokens generated.'));
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('date' => $date), array('language' => $language));
+      $output = token_replace($input, array('date' => $date), array('language' => $language_interface));
       $this->assertEqual($output, $expected, t('Date token %token replaced.', array('%token' => $input)));
     }
   }
@@ -2465,4 +2465,3 @@ class SystemIndexPhpTest extends DrupalWebTestCase {
     $this->assertResponse(404, t("Make sure index.php/user returns a 'page not found'."));
   }
 }
-
diff --git a/modules/taxonomy/taxonomy.test b/modules/taxonomy/taxonomy.test
index aa7cc2e..4c0c719 100644
--- a/modules/taxonomy/taxonomy.test
+++ b/modules/taxonomy/taxonomy.test
@@ -1147,7 +1147,7 @@ class TaxonomyTokenReplaceTestCase extends TaxonomyWebTestCase {
    * Creates some terms and a node, then tests the tokens generated from them.
    */
   function testTaxonomyTokenReplacement() {
-    global $language;
+    global $language_interface;
 
     // Create two taxonomy terms.
     $term1 = $this->createTerm($this->vocabulary);
@@ -1176,7 +1176,7 @@ class TaxonomyTokenReplaceTestCase extends TaxonomyWebTestCase {
     $tests['[term:vocabulary:name]'] = check_plain($this->vocabulary->name);
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('term' => $term1), array('language' => $language));
+      $output = token_replace($input, array('term' => $term1), array('language' => $language_interface));
       $this->assertEqual($output, $expected, t('Sanitized taxonomy term token %token replaced.', array('%token' => $input)));
     }
 
@@ -1196,7 +1196,7 @@ class TaxonomyTokenReplaceTestCase extends TaxonomyWebTestCase {
     $this->assertFalse(in_array(0, array_map('strlen', $tests)), t('No empty tokens generated.'));
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('term' => $term2), array('language' => $language));
+      $output = token_replace($input, array('term' => $term2), array('language' => $language_interface));
       $this->assertEqual($output, $expected, t('Sanitized taxonomy term token %token replaced.', array('%token' => $input)));
     }
 
@@ -1207,7 +1207,7 @@ class TaxonomyTokenReplaceTestCase extends TaxonomyWebTestCase {
     $tests['[term:vocabulary:name]'] = $this->vocabulary->name;
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('term' => $term2), array('language' => $language, 'sanitize' => FALSE));
+      $output = token_replace($input, array('term' => $term2), array('language' => $language_interface, 'sanitize' => FALSE));
       $this->assertEqual($output, $expected, t('Unsanitized taxonomy term token %token replaced.', array('%token' => $input)));
     }
 
@@ -1223,7 +1223,7 @@ class TaxonomyTokenReplaceTestCase extends TaxonomyWebTestCase {
     $this->assertFalse(in_array(0, array_map('strlen', $tests)), t('No empty tokens generated.'));
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('vocabulary' => $this->vocabulary), array('language' => $language));
+      $output = token_replace($input, array('vocabulary' => $this->vocabulary), array('language' => $language_interface));
       $this->assertEqual($output, $expected, t('Sanitized taxonomy vocabulary token %token replaced.', array('%token' => $input)));
     }
 
@@ -1232,7 +1232,7 @@ class TaxonomyTokenReplaceTestCase extends TaxonomyWebTestCase {
     $tests['[vocabulary:description]'] = $this->vocabulary->description;
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('vocabulary' => $this->vocabulary), array('language' => $language, 'sanitize' => FALSE));
+      $output = token_replace($input, array('vocabulary' => $this->vocabulary), array('language' => $language_interface, 'sanitize' => FALSE));
       $this->assertEqual($output, $expected, t('Unsanitized taxonomy vocabulary token %token replaced.', array('%token' => $input)));
     }
   }
diff --git a/modules/translation/translation.test b/modules/translation/translation.test
index fe320a9..e189871 100644
--- a/modules/translation/translation.test
+++ b/modules/translation/translation.test
@@ -49,7 +49,7 @@ class TranslationTestCase extends DrupalWebTestCase {
 
     // Enable URL language detection and selection to make the language switcher
     // block appear.
-    $edit = array('language[enabled][locale-url]' => TRUE);
+    $edit = array('language_interface[enabled][locale-url]' => TRUE);
     $this->drupalPost('admin/config/regional/language/configure', $edit, t('Save settings'));
     $this->assertRaw(t('Language negotiation configuration saved.'), t('URL language detection enabled.'));
     $this->resetCaches();
@@ -182,7 +182,7 @@ class TranslationTestCase extends DrupalWebTestCase {
     // Check that content translation links are shown even when no language
     // negotiation is configured.
     $this->drupalLogin($this->admin_user);
-    $edit = array('language[enabled][locale-url]' => FALSE);
+    $edit = array('language_interface[enabled][locale-url]' => FALSE);
     $this->drupalPost('admin/config/regional/language/configure', $edit, t('Save settings'));
     $this->resetCaches();
     $edit = array('status' => TRUE);
diff --git a/modules/user/user.pages.inc b/modules/user/user.pages.inc
index 09bf33b..7c9b9ff 100644
--- a/modules/user/user.pages.inc
+++ b/modules/user/user.pages.inc
@@ -72,11 +72,11 @@ function user_pass_validate($form, &$form_state) {
 }
 
 function user_pass_submit($form, &$form_state) {
-  global $language;
+  global $language_interface;
 
   $account = $form_state['values']['account'];
   // Mail one time login URL and instructions using current language.
-  _user_mail_notify('password_reset', $account, $language);
+  _user_mail_notify('password_reset', $account, $language_interface);
   watchdog('user', 'Password reset instructions mailed to %name at %email.', array('%name' => $account->name, '%email' => $account->mail));
   drupal_set_message(t('Further instructions have been sent to your e-mail address.'));
 
diff --git a/modules/user/user.test b/modules/user/user.test
index 6ecbfac..f1af3ef 100644
--- a/modules/user/user.test
+++ b/modules/user/user.test
@@ -1895,10 +1895,10 @@ class UserTokenReplaceTestCase extends DrupalWebTestCase {
    * Creates a user, then tests the tokens generated from it.
    */
   function testUserTokenReplacement() {
-    global $language;
+    global $language_interface;
     $url_options = array(
       'absolute' => TRUE,
-      'language' => $language,
+      'language' => $language_interface,
     );
 
     // Create two users and log them in one after another.
@@ -1918,17 +1918,17 @@ class UserTokenReplaceTestCase extends DrupalWebTestCase {
     $tests['[user:mail]'] = check_plain($account->mail);
     $tests['[user:url]'] = url("user/$account->uid", $url_options);
     $tests['[user:edit-url]'] = url("user/$account->uid/edit", $url_options);
-    $tests['[user:last-login]'] = format_date($account->login, 'medium', '', NULL, $language->language);
-    $tests['[user:last-login:short]'] = format_date($account->login, 'short', '', NULL, $language->language);
-    $tests['[user:created]'] = format_date($account->created, 'medium', '', NULL, $language->language);
-    $tests['[user:created:short]'] = format_date($account->created, 'short', '', NULL, $language->language);
+    $tests['[user:last-login]'] = format_date($account->login, 'medium', '', NULL, $language_interface->language);
+    $tests['[user:last-login:short]'] = format_date($account->login, 'short', '', NULL, $language_interface->language);
+    $tests['[user:created]'] = format_date($account->created, 'medium', '', NULL, $language_interface->language);
+    $tests['[user:created:short]'] = format_date($account->created, 'short', '', NULL, $language_interface->language);
     $tests['[current-user:name]'] = check_plain(format_username($global_account));
 
     // Test to make sure that we generated something for each token.
     $this->assertFalse(in_array(0, array_map('strlen', $tests)), t('No empty tokens generated.'));
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('user' => $account), array('language' => $language));
+      $output = token_replace($input, array('user' => $account), array('language' => $language_interface));
       $this->assertEqual($output, $expected, t('Sanitized user token %token replaced.', array('%token' => $input)));
     }
 
@@ -1938,7 +1938,7 @@ class UserTokenReplaceTestCase extends DrupalWebTestCase {
     $tests['[current-user:name]'] = format_username($global_account);
 
     foreach ($tests as $input => $expected) {
-      $output = token_replace($input, array('user' => $account), array('language' => $language, 'sanitize' => FALSE));
+      $output = token_replace($input, array('user' => $account), array('language' => $language_interface, 'sanitize' => FALSE));
       $this->assertEqual($output, $expected, t('Unsanitized user token %token replaced.', array('%token' => $input)));
     }
   }
