? modules/simpletest/tests/343502.test Index: update.php =================================================================== RCS file: /cvs/drupal/drupal/update.php,v retrieving revision 1.267 diff -u -p -r1.267 update.php --- update.php 24 Nov 2008 10:41:39 -0000 1.267 +++ update.php 8 Dec 2008 23:41:35 -0000 @@ -53,7 +53,7 @@ define('MAINTENANCE_MODE', 'update'); * @return * nothing, but modifies $ret parameter. */ -function db_add_column(&$ret, $table, $column, $type, $attributes = array()) { +function db_add_column(&$ret, $table, $column, $type, array $attributes = array()) { if (array_key_exists('not null', $attributes) and $attributes['not null']) { $not_null = 'NOT NULL'; } @@ -109,7 +109,7 @@ function db_add_column(&$ret, $table, $c * @return * nothing, but modifies $ret parameter. */ -function db_change_column(&$ret, $table, $column, $column_new, $type, $attributes = array()) { +function db_change_column(&$ret, $table, $column, $column_new, $type, array $attributes = array()) { if (array_key_exists('not null', $attributes) and $attributes['not null']) { $not_null = 'NOT NULL'; } Index: includes/common.inc =================================================================== RCS file: /cvs/drupal/drupal/includes/common.inc,v retrieving revision 1.835 diff -u -p -r1.835 common.inc --- includes/common.inc 7 Dec 2008 08:23:07 -0000 1.835 +++ includes/common.inc 8 Dec 2008 23:44:43 -0000 @@ -234,7 +234,7 @@ function drupal_get_feeds($delimiter = " * @return * An urlencoded string which can be appended to/as the URL query string. */ -function drupal_query_string_encode($query, $exclude = array(), $parent = '') { +function drupal_query_string_encode($query, array $exclude = array(), $parent = '') { $params = array(); foreach ($query as $key => $value) { @@ -440,7 +440,7 @@ function drupal_access_denied() { * An object containing the HTTP request headers, response code, headers, * data and redirect status. */ -function drupal_http_request($url, $headers = array(), $method = 'GET', $data = NULL, $retry = 3) { +function drupal_http_request($url, array $headers = array(), $method = 'GET', $data = NULL, $retry = 3) { global $db_prefix; static $self_test = FALSE; $result = new stdClass(); @@ -1037,7 +1037,7 @@ function fix_gpc_magic() { * @return * The translated string. */ -function t($string, $args = array(), $langcode = NULL) { +function t($string, array $args = array(), $langcode = NULL) { global $language; static $custom_strings; @@ -1193,7 +1193,7 @@ function check_url($uri) { * * Arbitrary elements may be added using the $args associative array. */ -function format_rss_channel($title, $link, $description, $items, $langcode = NULL, $args = array()) { +function format_rss_channel($title, $link, $description, $items, $langcode = NULL, array $args = array()) { global $language; $langcode = $langcode ? $langcode : $language->language; @@ -1218,7 +1218,7 @@ function format_rss_channel($title, $lin * * Arbitrary elements may be added using the $args associative array. */ -function format_rss_item($title, $link, $description, $args = array()) { +function format_rss_item($title, $link, $description, array $args = array()) { $output = "\n"; $output .= ' ' . check_plain($title) . "\n"; $output .= ' ' . check_url($link) . "\n"; @@ -1314,7 +1314,7 @@ function format_xml_elements($array) { * @return * A translated string. */ -function format_plural($count, $singular, $plural, $args = array(), $langcode = NULL) { +function format_plural($count, $singular, $plural, array $args = array(), $langcode = NULL) { $args['@count'] = $count; if ($count == 1) { return t($singular, $args, $langcode); @@ -1684,14 +1684,12 @@ function url($path = NULL, array $option * @return * An HTML string ready for insertion in a tag. */ -function drupal_attributes($attributes = array()) { - if (is_array($attributes)) { - $t = ''; - foreach ($attributes as $key => $value) { - $t .= " $key=" . '"' . check_plain($value) . '"'; - } - return $t; +function drupal_attributes(array $attributes = array()) { + $t = ''; + foreach ($attributes as $key => $value) { + $t .= " $key=" . '"' . check_plain($value) . '"'; } + return $t; } /** Index: includes/unicode.inc =================================================================== RCS file: /cvs/drupal/drupal/includes/unicode.inc,v retrieving revision 1.35 diff -u -p -r1.35 unicode.inc --- includes/unicode.inc 5 Nov 2008 12:58:59 -0000 1.35 +++ includes/unicode.inc 8 Dec 2008 23:41:35 -0000 @@ -322,7 +322,7 @@ function _mime_header_decode($matches) { * An array of characters which should not be decoded. For example, * array('<', '&', '"'). This affects both named and numerical entities. */ -function decode_entities($text, $exclude = array()) { +function decode_entities($text, array $exclude = array()) { static $table; // We store named entities in a table for quick processing. if (!isset($table)) { @@ -335,9 +335,9 @@ function decode_entities($text, $exclude } $newtable = array_diff($table, $exclude); - // Use a regexp to select all entities in one pass, to avoid decoding + // Use a regexp to select all entities in one pass, to avoid decoding // double-escaped entities twice. The PREG_REPLACE_EVAL modifier 'e' is - // being used to allow for a callback (see + // being used to allow for a callback (see // http://php.net/manual/en/reference.pcre.pattern.modifiers). return preg_replace('/&(#x?)?([A-Za-z0-9]+);/e', '_decode_entities("$1", "$2", "$0", $newtable, $exclude)', $text); } @@ -535,5 +535,3 @@ function drupal_substr($text, $start, $l return substr($text, $istart, max(0, $iend - $istart + 1)); } } - - Index: includes/database/database.inc =================================================================== RCS file: /cvs/drupal/drupal/includes/database/database.inc,v retrieving revision 1.33 diff -u -p -r1.33 database.inc --- includes/database/database.inc 8 Dec 2008 21:41:53 -0000 1.33 +++ includes/database/database.inc 8 Dec 2008 23:41:37 -0000 @@ -1265,7 +1265,7 @@ interface DatabaseStatementInterface ext * @return * TRUE on success, or FALSE on failure. */ - public function execute($args, $options); + public function execute(array $args = array(), array $options = array()); /** * Get the query string of that statement. @@ -1442,7 +1442,7 @@ class DatabaseStatementBase extends PDOS $this->setFetchMode(PDO::FETCH_OBJ); } - public function execute($args, $options) { + public function execute(array $args = array(), array $options = array()) { if (isset($options['fetch'])) { if (is_string($options['fetch'])) { // Default to an object. Note: db fields will be added to the object @@ -1542,7 +1542,7 @@ class DatabaseStatementBase extends PDOS * @return * A prepared statement object, already executed. */ -function db_query($query, $args = array(), $options = array()) { +function db_query($query, array $args = array(), array $options = array()) { if (!is_array($args)) { $args = func_get_args(); array_shift($args); @@ -1574,7 +1574,7 @@ function db_query($query, $args = array( * @return * A prepared statement object, already executed. */ -function db_query_range($query, $args, $from = 0, $count = 0, $options = array()) { +function db_query_range($query, $args, $from = 0, $count = 0, array $options = array()) { if (!is_array($args)) { $args = func_get_args(); array_shift($args); @@ -1976,7 +1976,7 @@ function db_drop_table(&$ret, $table) { * or index including it in this array. @see db_change_field for more * explanation why. */ -function db_add_field(&$ret, $table, $field, $spec, $keys_new = array()) { +function db_add_field(&$ret, $table, $field, $spec, array $keys_new = array()) { return Database::getActiveConnection()->schema()->addField($ret, $table, $field, $spec, $keys_new); } @@ -2173,7 +2173,7 @@ function db_drop_index(&$ret, $table, $n * table specification but without the 'fields' element. */ -function db_change_field(&$ret, $table, $field, $field_new, $spec, $keys_new = array()) { +function db_change_field(&$ret, $table, $field, $field_new, $spec, array $keys_new = array()) { return Database::getActiveConnection()->schema()->changeField($ret, $table, $field, $field_new, $spec, $keys_new); } @@ -2326,7 +2326,7 @@ function db_affected_rows() { * @return * An array: join statements, where statements, field or DISTINCT(field). */ -function _db_rewrite_sql($query = '', $primary_table = 'n', $primary_field = 'nid', $args = array()) { +function _db_rewrite_sql($query = '', $primary_table = 'n', $primary_field = 'nid', array $args = array()) { $where = array(); $join = array(); $distinct = FALSE; @@ -2374,7 +2374,7 @@ function _db_rewrite_sql($query = '', $p * The original query with JOIN and WHERE statements inserted from * hook_db_rewrite_sql implementations. nid is rewritten if needed. */ -function db_rewrite_sql($query, $primary_table = 'n', $primary_field = 'nid', $args = array()) { +function db_rewrite_sql($query, $primary_table = 'n', $primary_field = 'nid', array $args = array()) { list($join, $where, $distinct) = _db_rewrite_sql($query, $primary_table, $primary_field, $args); if ($distinct) { Index: includes/database/prefetch.inc =================================================================== RCS file: /cvs/drupal/drupal/includes/database/prefetch.inc,v retrieving revision 1.2 diff -u -p -r1.2 prefetch.inc --- includes/database/prefetch.inc 8 Dec 2008 21:41:53 -0000 1.2 +++ includes/database/prefetch.inc 8 Dec 2008 23:41:37 -0000 @@ -135,7 +135,7 @@ class DatabaseStatementPrefetch implemen * @return * TRUE on success, or FALSE on failure. */ - public function execute($args, $options) { + public function execute(array $args = array(), array $options = array()) { if (isset($options['fetch'])) { if (is_string($options['fetch'])) { // Default to an object. Note: db fields will be added to the object @@ -500,4 +500,3 @@ class DatabaseStatementPrefetch implemen /** * @} End of "ingroup database". */ - Index: includes/database/sqlite/database.inc =================================================================== RCS file: /cvs/drupal/drupal/includes/database/sqlite/database.inc,v retrieving revision 1.7 diff -u -p -r1.7 database.inc --- includes/database/sqlite/database.inc 8 Dec 2008 21:41:53 -0000 1.7 +++ includes/database/sqlite/database.inc 8 Dec 2008 23:41:38 -0000 @@ -211,7 +211,7 @@ class DatabaseStatement_sqlite extends D return $this->dbh->PDOPrepare($query); } - public function execute($args, $options) { + public function execute(array $args = array(), array $options = array()) { try { $return = parent::execute($args, $options); } Index: modules/aggregator/aggregator.module =================================================================== RCS file: /cvs/drupal/drupal/modules/aggregator/aggregator.module,v retrieving revision 1.401 diff -u -p -r1.401 aggregator.module --- modules/aggregator/aggregator.module 16 Nov 2008 04:38:15 -0000 1.401 +++ modules/aggregator/aggregator.module 8 Dec 2008 23:41:38 -0000 @@ -298,7 +298,7 @@ function aggregator_cron() { * * Generates blocks for the latest news items in each category and feed. */ -function aggregator_block($op = 'list', $delta = '', $edit = array()) { +function aggregator_block($op = 'list', $delta = '', array $edit = array()) { if (user_access('access news feeds')) { if ($op == 'list') { $result = db_query('SELECT cid, title FROM {aggregator_category} ORDER BY title'); Index: modules/block/block.api.php =================================================================== RCS file: /cvs/drupal/drupal/modules/block/block.api.php,v retrieving revision 1.1 diff -u -p -r1.1 block.api.php --- modules/block/block.api.php 25 Nov 2008 02:37:31 -0000 1.1 +++ modules/block/block.api.php 8 Dec 2008 23:41:38 -0000 @@ -75,7 +75,7 @@ * * For a detailed usage example, see block_example.module. */ -function hook_block($op = 'list', $delta = '', $edit = array()) { +function hook_block($op = 'list', $delta = '', array $edit = array()) { if ($op == 'list') { $blocks['exciting'] = array( 'info' => t('An exciting block provided by Mymodule.'), Index: modules/block/block.module =================================================================== RCS file: /cvs/drupal/drupal/modules/block/block.module,v retrieving revision 1.315 diff -u -p -r1.315 block.module --- modules/block/block.module 15 Nov 2008 08:23:07 -0000 1.315 +++ modules/block/block.module 8 Dec 2008 23:41:39 -0000 @@ -184,7 +184,7 @@ function _block_themes_access($theme) { * * Generates the administrator-defined blocks for display. */ -function block_block($op = 'list', $delta = 0, $edit = array()) { +function block_block($op = 'list', $delta = 0, array $edit = array()) { switch ($op) { case 'list': $blocks = array(); @@ -302,7 +302,7 @@ function block_box_get($bid) { /** * Define the custom block form. */ -function block_box_form($edit = array()) { +function block_box_form(array $edit = array()) { $edit += array( 'info' => '', 'body' => '', Index: modules/book/book.module =================================================================== RCS file: /cvs/drupal/drupal/modules/book/book.module,v retrieving revision 1.476 diff -u -p -r1.476 book.module --- modules/book/book.module 5 Dec 2008 22:18:44 -0000 1.476 +++ modules/book/book.module 8 Dec 2008 23:41:40 -0000 @@ -185,7 +185,7 @@ function book_init() { * Displays the book table of contents in a block when the current page is a * single-node view of a book node. */ -function book_block($op = 'list', $delta = '', $edit = array()) { +function book_block($op = 'list', $delta = '', array $edit = array()) { $block = array(); switch ($op) { case 'list': @@ -951,7 +951,7 @@ function _book_toc_recurse($tree, $inden * @return * An array of mlid, title pairs for use as options for selecting a book page. */ -function book_toc($bid, $exclude = array(), $depth_limit) { +function book_toc($bid, array $exclude = array(), $depth_limit) { $tree = menu_tree_all_data(book_menu_name($bid)); $toc = array(); _book_toc_recurse($tree, '', $toc, $exclude, $depth_limit); Index: modules/comment/comment.module =================================================================== RCS file: /cvs/drupal/drupal/modules/comment/comment.module,v retrieving revision 1.669 diff -u -p -r1.669 comment.module --- modules/comment/comment.module 5 Dec 2008 22:18:44 -0000 1.669 +++ modules/comment/comment.module 8 Dec 2008 23:41:42 -0000 @@ -265,7 +265,7 @@ function comment_perm() { * * Generates a block with the most recent comments. */ -function comment_block($op = 'list', $delta = '', $edit = array()) { +function comment_block($op = 'list', $delta = '', array $edit = array()) { switch ($op) { case 'list': $blocks['recent']['info'] = t('Recent comments'); @@ -1684,7 +1684,7 @@ function comment_form_submit($form, &$fo * Switches between folded/unfolded view. * @ingroup themeable */ -function theme_comment_view($comment, $node, $links = array(), $visible = TRUE) { +function theme_comment_view($comment, $node, array $links = array(), $visible = TRUE) { static $first_new = TRUE; $comment->new = node_mark($comment->nid, $comment->timestamp); $output = ''; @@ -2065,7 +2065,7 @@ function comment_action_info() { * @param $comment * An optional comment object. */ -function comment_unpublish_action($comment, $context = array()) { +function comment_unpublish_action($comment, array $context = array()) { if (isset($comment->cid)) { $cid = $comment->cid; $subject = $comment->subject; Index: modules/contact/contact.admin.inc =================================================================== RCS file: /cvs/drupal/drupal/modules/contact/contact.admin.inc,v retrieving revision 1.5 diff -u -p -r1.5 contact.admin.inc --- modules/contact/contact.admin.inc 2 Jul 2008 20:05:11 -0000 1.5 +++ modules/contact/contact.admin.inc 8 Dec 2008 23:41:43 -0000 @@ -23,7 +23,7 @@ function contact_admin_categories() { /** * Category edit page. */ -function contact_admin_edit($form_state = array(), $op, $contact = NULL) { +function contact_admin_edit(array $form_state = array(), $op, $contact = NULL) { if (empty($contact) || $op == 'add') { $contact = array( Index: modules/dblog/dblog.module =================================================================== RCS file: /cvs/drupal/drupal/modules/dblog/dblog.module,v retrieving revision 1.30 diff -u -p -r1.30 dblog.module --- modules/dblog/dblog.module 30 Oct 2008 09:16:01 -0000 1.30 +++ modules/dblog/dblog.module 8 Dec 2008 23:41:43 -0000 @@ -118,7 +118,7 @@ function _dblog_get_message_types() { return $types; } -function dblog_watchdog($log = array()) { +function dblog_watchdog(array $log) { Database::getConnection('default')->insert('watchdog') ->fields(array( 'uid' => $log['user']->uid, @@ -148,4 +148,3 @@ function theme_dblog_filters($form) { $output .= '
' . drupal_render($form['buttons']) . '
'; return $output; } - Index: modules/forum/forum.admin.inc =================================================================== RCS file: /cvs/drupal/drupal/modules/forum/forum.admin.inc,v retrieving revision 1.15 diff -u -p -r1.15 forum.admin.inc --- modules/forum/forum.admin.inc 5 Nov 2008 14:08:11 -0000 1.15 +++ modules/forum/forum.admin.inc 8 Dec 2008 23:41:43 -0000 @@ -27,7 +27,7 @@ function forum_form_main($type, $edit = * @ingroup forms * @see forum_form_submit() */ -function forum_form_forum(&$form_state, $edit = array()) { +function forum_form_forum(&$form_state, array $edit = array()) { $edit += array( 'name' => '', 'description' => '', @@ -105,7 +105,7 @@ function forum_form_submit($form, &$form * @ingroup forms * @see forum_form_submit() */ -function forum_form_container(&$form_state, $edit = array()) { +function forum_form_container(&$form_state, array $edit = array()) { $edit += array( 'name' => '', 'description' => '', Index: modules/forum/forum.module =================================================================== RCS file: /cvs/drupal/drupal/modules/forum/forum.module,v retrieving revision 1.474 diff -u -p -r1.474 forum.module --- modules/forum/forum.module 5 Dec 2008 22:18:44 -0000 1.474 +++ modules/forum/forum.module 8 Dec 2008 23:41:45 -0000 @@ -471,7 +471,7 @@ function forum_form_alter(&$form, $form_ * Generates a block containing the currently active forum topics and the * most recently added forum topics. */ -function forum_block($op = 'list', $delta = '', $edit = array()) { +function forum_block($op = 'list', $delta = '', array $edit = array()) { switch ($op) { case 'list': $blocks['active']['info'] = t('Active forum topics'); Index: modules/menu/menu.admin.inc =================================================================== RCS file: /cvs/drupal/drupal/modules/menu/menu.admin.inc,v retrieving revision 1.34 diff -u -p -r1.34 menu.admin.inc --- modules/menu/menu.admin.inc 15 Nov 2008 08:23:07 -0000 1.34 +++ modules/menu/menu.admin.inc 8 Dec 2008 23:41:45 -0000 @@ -384,7 +384,7 @@ function menu_edit_item_submit($form, &$ /** * Menu callback; Build the form that handles the adding/editing of a custom menu. */ -function menu_edit_menu(&$form_state, $type, $menu = array()) { +function menu_edit_menu(&$form_state, $type, array $menu = array()) { if ($type == 'edit') { $form['menu_name'] = array('#type' => 'value', '#value' => $menu['menu_name']); $form['#insert'] = FALSE; Index: modules/node/node.module =================================================================== RCS file: /cvs/drupal/drupal/modules/node/node.module,v retrieving revision 1.1001 diff -u -p -r1.1001 node.module --- modules/node/node.module 5 Dec 2008 22:18:45 -0000 1.1001 +++ modules/node/node.module 8 Dec 2008 23:41:47 -0000 @@ -628,7 +628,7 @@ function _node_types_build() { * @return * A node type object. */ -function node_type_set_defaults($info = array()) { +function node_type_set_defaults(array $info = array()) { static $type; if (!isset($type)) { @@ -746,7 +746,7 @@ function node_invoke_nodeapi(&$node, $op * @return * An array of node objects indexed by nid. */ -function node_load_multiple($nids = array(), $conditions = array(), $reset = FALSE) { +function node_load_multiple(array $nids = array(), array $conditions = array(), $reset = FALSE) { static $node_cache = array(); if ($reset) { $node_cache = array(); @@ -896,7 +896,7 @@ function node_load_multiple($nids = arra * @return * A fully-populated node object. */ -function node_load($nid, $vid = array(), $reset = FALSE) { +function node_load($nid, array $vid = array(), $reset = FALSE) { $vid = isset($vid) ? array('vid' => $vid) : NULL; $node = node_load_multiple(array($nid), $vid, $reset); @@ -906,7 +906,7 @@ function node_load($nid, $vid = array(), /** * Perform validation checks on the given node. */ -function node_validate($node, $form = array()) { +function node_validate($node, array $form = array()) { // Convert the node to an object, if necessary. $node = (object)$node; $type = node_get_types('type', $node); @@ -1820,7 +1820,7 @@ function node_block($op = 'list', $delta * An associative array containing title, link, description and other keys. * The link should be an absolute URL. */ -function node_feed($nids = FALSE, $channel = array()) { +function node_feed($nids = FALSE, array $channel = array()) { global $base_url, $language; if ($nids === FALSE) { @@ -2810,7 +2810,7 @@ function node_action_info() { * Implementation of a Drupal action. * Sets the status of a node to 1, meaning published. */ -function node_publish_action(&$node, $context = array()) { +function node_publish_action(&$node, array $context = array()) { $node->status = 1; watchdog('action', 'Set @type %title to published.', array('@type' => node_get_types('name', $node), '%title' => $node->title)); } @@ -2819,7 +2819,7 @@ function node_publish_action(&$node, $co * Implementation of a Drupal action. * Sets the status of a node to 0, meaning unpublished. */ -function node_unpublish_action(&$node, $context = array()) { +function node_unpublish_action(&$node, array $context = array()) { $node->status = 0; watchdog('action', 'Set @type %title to unpublished.', array('@type' => node_get_types('name', $node), '%title' => $node->title)); } @@ -2828,7 +2828,7 @@ function node_unpublish_action(&$node, $ * Implementation of a Drupal action. * Sets the sticky-at-top-of-list property of a node to 1. */ -function node_make_sticky_action(&$node, $context = array()) { +function node_make_sticky_action(&$node, array $context = array()) { $node->sticky = 1; watchdog('action', 'Set @type %title to sticky.', array('@type' => node_get_types('name', $node), '%title' => $node->title)); } @@ -2837,7 +2837,7 @@ function node_make_sticky_action(&$node, * Implementation of a Drupal action. * Sets the sticky-at-top-of-list property of a node to 0. */ -function node_make_unsticky_action(&$node, $context = array()) { +function node_make_unsticky_action(&$node, array $context = array()) { $node->sticky = 0; watchdog('action', 'Set @type %title to unsticky.', array('@type' => node_get_types('name', $node), '%title' => $node->title)); } @@ -2846,7 +2846,7 @@ function node_make_unsticky_action(&$nod * Implementation of a Drupal action. * Sets the promote property of a node to 1. */ -function node_promote_action(&$node, $context = array()) { +function node_promote_action(&$node, array $context = array()) { $node->promote = 1; watchdog('action', 'Promoted @type %title to front page.', array('@type' => node_get_types('name', $node), '%title' => $node->title)); } @@ -2855,7 +2855,7 @@ function node_promote_action(&$node, $co * Implementation of a Drupal action. * Sets the promote property of a node to 0. */ -function node_unpromote_action(&$node, $context = array()) { +function node_unpromote_action(&$node, array $context = array()) { $node->promote = 0; watchdog('action', 'Removed @type %title from front page.', array('@type' => node_get_types('name', $node), '%title' => $node->title)); } Index: modules/openid/openid.module =================================================================== RCS file: /cvs/drupal/drupal/modules/openid/openid.module,v retrieving revision 1.33 diff -u -p -r1.33 openid.module --- modules/openid/openid.module 22 Nov 2008 10:32:42 -0000 1.33 +++ modules/openid/openid.module 8 Dec 2008 23:41:48 -0000 @@ -149,7 +149,7 @@ function openid_login_validate($form, &$ * @param $claimed_id The OpenID to authenticate * @param $return_to The endpoint to return to from the OpenID Provider */ -function openid_begin($claimed_id, $return_to = '', $form_values = array()) { +function openid_begin($claimed_id, $return_to = '', array $form_values = array()) { module_load_include('inc', 'openid'); $claimed_id = _openid_normalize($claimed_id); @@ -211,7 +211,7 @@ function openid_begin($claimed_id, $retu * @return $response Response values for further processing with * $response['status'] set to one of 'success', 'failed' or 'cancel'. */ -function openid_complete($response = array()) { +function openid_complete(array $response = array()) { module_load_include('inc', 'openid'); if (count($response) == 0) { Index: modules/profile/profile.module =================================================================== RCS file: /cvs/drupal/drupal/modules/profile/profile.module,v retrieving revision 1.247 diff -u -p -r1.247 profile.module --- modules/profile/profile.module 5 Dec 2008 12:50:28 -0000 1.247 +++ modules/profile/profile.module 8 Dec 2008 23:41:48 -0000 @@ -128,7 +128,7 @@ function profile_menu() { /** * Implementation of hook_block(). */ -function profile_block($op = 'list', $delta = '', $edit = array()) { +function profile_block($op = 'list', $delta = '', array $edit = array()) { if ($op == 'list') { $blocks['author-information']['info'] = t('Author information'); @@ -607,4 +607,3 @@ function _profile_get_fields($category, $sql .= ' ORDER BY category, weight'; return db_query($sql, $args); } - Index: modules/search/search.module =================================================================== RCS file: /cvs/drupal/drupal/modules/search/search.module,v retrieving revision 1.277 diff -u -p -r1.277 search.module --- modules/search/search.module 3 Dec 2008 16:32:22 -0000 1.277 +++ modules/search/search.module 8 Dec 2008 23:41:49 -0000 @@ -923,7 +923,7 @@ function _search_parse_query(&$word, &$s * * @ingroup search */ -function do_search($keywords, $type, $join1 = '', $where1 = '1 = 1', $arguments1 = array(), $columns2 = 'SUM(i.relevance) AS calculated_score', $join2 = '', $arguments2 = array(), $sort_parameters = 'ORDER BY calculated_score DESC') { +function do_search($keywords, $type, $join1 = '', $where1 = '1 = 1', array $arguments1 = array(), $columns2 = 'SUM(i.relevance) AS calculated_score', $join2 = '', array $arguments2 = array(), $sort_parameters = 'ORDER BY calculated_score DESC') { $query = search_parse_query($keywords); if ($query[2] == '') { Index: modules/simpletest/tests/session_test.module =================================================================== RCS file: /cvs/drupal/drupal/modules/simpletest/tests/session_test.module,v retrieving revision 1.4 diff -u -p -r1.4 session_test.module --- modules/simpletest/tests/session_test.module 24 Nov 2008 06:12:45 -0000 1.4 +++ modules/simpletest/tests/session_test.module 8 Dec 2008 23:41:49 -0000 @@ -75,11 +75,10 @@ function _session_test_id() { /** * Implementation of hook_user(). */ -function session_test_user_login($edit = array(), $user = NULL) { +function session_test_user_login(array $edit = array(), $user = NULL) { if ($edit['name'] == 'session_test_user') { // Exit so we can verify that the session was regenerated // before hook_user() was called. exit; } } - Index: modules/statistics/statistics.module =================================================================== RCS file: /cvs/drupal/drupal/modules/statistics/statistics.module,v retrieving revision 1.287 diff -u -p -r1.287 statistics.module --- modules/statistics/statistics.module 2 Dec 2008 21:24:34 -0000 1.287 +++ modules/statistics/statistics.module 8 Dec 2008 23:41:50 -0000 @@ -252,7 +252,7 @@ function statistics_get($nid) { /** * Implementation of hook_block(). */ -function statistics_block($op = 'list', $delta = '', $edit = array()) { +function statistics_block($op = 'list', $delta = '', array $edit = array()) { switch ($op) { case 'list': if (variable_get('statistics_count_content_views', 0)) { Index: modules/syslog/syslog.module =================================================================== RCS file: /cvs/drupal/drupal/modules/syslog/syslog.module,v retrieving revision 1.18 diff -u -p -r1.18 syslog.module --- modules/syslog/syslog.module 31 Aug 2008 09:15:13 -0000 1.18 +++ modules/syslog/syslog.module 8 Dec 2008 23:41:50 -0000 @@ -68,7 +68,7 @@ function syslog_facility_list() { return $facility_list; } -function syslog_watchdog($entry) { +function syslog_watchdog(array $entry) { static $log_init = FALSE; if (!$log_init) { @@ -92,7 +92,7 @@ function syslog_theme() { * * @ingroup themeable */ -function theme_syslog_format($entry) { +function theme_syslog_format(array $entry) { global $base_url; $message = $base_url; Index: modules/system/system.admin.inc =================================================================== RCS file: /cvs/drupal/drupal/modules/system/system.admin.inc,v retrieving revision 1.110 diff -u -p -r1.110 system.admin.inc --- modules/system/system.admin.inc 26 Nov 2008 13:54:05 -0000 1.110 +++ modules/system/system.admin.inc 8 Dec 2008 23:41:53 -0000 @@ -604,7 +604,7 @@ function _system_is_incompatible(&$incom * @return * The form array. */ -function system_modules($form_state = array()) { +function system_modules(array $form_state = array()) { // Clear all caches. registry_rebuild(); drupal_theme_rebuild(); Index: modules/system/system.module =================================================================== RCS file: /cvs/drupal/drupal/modules/system/system.module,v retrieving revision 1.650 diff -u -p -r1.650 system.module --- modules/system/system.module 28 Nov 2008 09:25:59 -0000 1.650 +++ modules/system/system.module 8 Dec 2008 23:41:56 -0000 @@ -1199,7 +1199,7 @@ function _system_theme_data() { * @return * Returns the top level parent that has no ancestor or returns NULL if there isn't a valid parent. */ -function system_find_base_theme($themes, $key, $used_keys = array()) { +function system_find_base_theme($themes, $key, array $used_keys = array()) { $base_key = $themes[$key]->info['base theme']; // Does the base theme exist? if (!isset($themes[$base_key])) { @@ -1654,7 +1654,7 @@ function system_actions_manage() { * @return * Form definition. */ -function system_actions_manage_form($form_state, $options = array()) { +function system_actions_manage_form($form_state, array $options = array()) { $form['parent'] = array( '#type' => 'fieldset', '#title' => t('Make a new advanced action available'), @@ -2052,7 +2052,7 @@ function system_message_action_submit($f /** * A configurable Drupal action. Sends a message to the current user's screen. */ -function system_message_action(&$object, $context = array()) { +function system_message_action(&$object, array $context = array()) { global $user; $variables = array( '%site_name' => variable_get('site_name', 'Drupal'), Index: modules/taxonomy/taxonomy.admin.inc =================================================================== RCS file: /cvs/drupal/drupal/modules/taxonomy/taxonomy.admin.inc,v retrieving revision 1.37 diff -u -p -r1.37 taxonomy.admin.inc --- modules/taxonomy/taxonomy.admin.inc 13 Nov 2008 08:13:56 -0000 1.37 +++ modules/taxonomy/taxonomy.admin.inc 8 Dec 2008 23:41:56 -0000 @@ -100,7 +100,7 @@ function theme_taxonomy_overview_vocabul * @ingroup forms * @see taxonomy_form_vocabulary_submit() */ -function taxonomy_form_vocabulary(&$form_state, $edit = array()) { +function taxonomy_form_vocabulary(&$form_state, array $edit = array()) { if (!is_array($edit)) { $edit = (array)$edit; } @@ -617,7 +617,7 @@ function theme_taxonomy_overview_terms($ * @ingroup forms * @see taxonomy_form_term_submit() */ -function taxonomy_form_term(&$form_state, $vocabulary, $edit = array()) { +function taxonomy_form_term(&$form_state, $vocabulary, array $edit = array()) { $edit += array( 'name' => '', 'description' => '', Index: modules/taxonomy/taxonomy.module =================================================================== RCS file: /cvs/drupal/drupal/modules/taxonomy/taxonomy.module,v retrieving revision 1.446 diff -u -p -r1.446 taxonomy.module --- modules/taxonomy/taxonomy.module 8 Dec 2008 21:54:33 -0000 1.446 +++ modules/taxonomy/taxonomy.module 8 Dec 2008 23:41:56 -0000 @@ -334,7 +334,7 @@ function taxonomy_term_save($term) { $status = drupal_write_record('term_data', $term); module_invoke_all('taxonomy_term_update', $term); } - + $or = db_or()->condition('tid1', $term->tid)->condition('tid2', $term->tid); db_delete('term_relation')->condition($or)->execute(); @@ -1093,7 +1093,7 @@ function taxonomy_terms_load($str_tids) * @return * An array of term objects, indexed by tid. */ -function taxonomy_term_load_multiple($tids = array(), $conditions = array(), $reset = FALSE) { +function taxonomy_term_load_multiple(array $tids = array(), array $conditions = array(), $reset = FALSE) { static $term_cache = array(); if ($reset) { @@ -1213,7 +1213,7 @@ function taxonomy_get_term_data($tid, $r return $terms[$tid]; } -function _taxonomy_term_select($title, $name, $value, $vocabulary_id, $description, $multiple, $blank, $exclude = array()) { +function _taxonomy_term_select($title, $name, $value, $vocabulary_id, $description, $multiple, $blank, array $exclude = array()) { $tree = taxonomy_get_tree($vocabulary_id); $options = array(); @@ -1270,7 +1270,7 @@ function theme_taxonomy_term_select($ele * @return * A resource identifier pointing to the query results. */ -function taxonomy_select_nodes($tids = array(), $operator = 'or', $depth = 0, $pager = TRUE, $order = 'n.sticky DESC, n.created DESC') { +function taxonomy_select_nodes(array $tids = array(), $operator = 'or', $depth = 0, $pager = TRUE, $order = 'n.sticky DESC, n.created DESC') { if (count($tids) > 0) { // For each term ID, generate an array of descendant term IDs to the right depth. $descendant_tids = array(); Index: modules/user/user.module =================================================================== RCS file: /cvs/drupal/drupal/modules/user/user.module,v retrieving revision 1.944 diff -u -p -r1.944 user.module --- modules/user/user.module 29 Nov 2008 09:33:51 -0000 1.944 +++ modules/user/user.module 8 Dec 2008 23:41:59 -0000 @@ -110,7 +110,7 @@ function user_external_load($authname) { * @return boolean * TRUE if the login succeeds, FALSE otherwise. */ -function user_external_login($account, $edit = array()) { +function user_external_login($account, array $edit = array()) { $form = drupal_get_form('user_login'); $state['values'] = $edit; @@ -214,7 +214,7 @@ function user_load($array = array()) { * @return * A fully-loaded $user object upon successful save or FALSE if the save failed. */ -function user_save($account, $edit = array(), $category = 'account') { +function user_save($account, array $edit = array(), $category = 'account') { $table = drupal_get_schema('users'); $user_fields = $table['fields']; @@ -461,7 +461,7 @@ function user_password($length = 10) { * An array indexed by role ID. Each value is an array whose keys are the * permission strings for the given role ID. */ -function user_role_permissions($roles = array(), $reset = FALSE) { +function user_role_permissions(array $roles = array(), $reset = FALSE) { static $stored_permissions = array(); if ($reset) { @@ -735,7 +735,7 @@ function user_login_block() { /** * Implementation of hook_block(). */ -function user_block($op = 'list', $delta = '', $edit = array()) { +function user_block($op = 'list', $delta = '', array $edit = array()) { global $user; if ($op == 'list') { @@ -1319,7 +1319,7 @@ function user_login_final_validate($form * @return * A $user object, if successful. */ -function user_authenticate($form_values = array()) { +function user_authenticate(array $form_values = array()) { global $user; $password = trim($form_values['pass']); @@ -1620,7 +1620,7 @@ function user_mail($key, &$message, $par * * Used by user_mail() and the settings forms to retrieve strings. */ -function _user_mail_text($key, $language = NULL, $variables = array()) { +function _user_mail_text($key, $language = NULL, array $variables = array()) { $langcode = isset($language) ? $language->language : NULL; if ($admin_setting = variable_get('user_mail_' . $key, FALSE)) { @@ -1717,7 +1717,7 @@ function user_roles($membersonly = FALSE /** * Implementation of hook_user_operations(). */ -function user_user_operations($form_state = array()) { +function user_user_operations(array $form_state = array()) { $operations = array( 'unblock' => array( 'label' => t('Unblock the selected users'), @@ -2219,7 +2219,7 @@ function user_action_info() { * Implementation of a Drupal action. * Blocks the current user. */ -function user_block_user_action(&$object, $context = array()) { +function user_block_user_action(&$object, array $context = array()) { if (isset($object->uid)) { $uid = $object->uid; } @@ -2418,4 +2418,3 @@ function _user_forms(&$edit, $account, $ return empty($groups) ? FALSE : $groups; } -