diff options
author | Nicola Pero <nicola.pero@meta-innovation.com> | 2011-04-12 19:02:14 +0000 |
---|---|---|
committer | Nicola Pero <nicola@gcc.gnu.org> | 2011-04-12 19:02:14 +0000 |
commit | eb345401a1a2f6408fddd8538466be1143a95177 (patch) | |
tree | dd0661e72bba2ceb2c1565779cd6d02900e5e871 | |
parent | dc2dc51254b9c3802424e2d3fc9cbb3d73fff909 (diff) | |
download | gcc-eb345401a1a2f6408fddd8538466be1143a95177.zip gcc-eb345401a1a2f6408fddd8538466be1143a95177.tar.gz gcc-eb345401a1a2f6408fddd8538466be1143a95177.tar.bz2 |
In gcc/: 2011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
In gcc/:
2011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
* c-parser.c (c_parser_initelt): Updated call to
objc_build_message_expr.
(c_parser_postfix_expression): Likewise.
In gcc/c-family/:
2011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
* c-objc.h (objc_build_message_expr): Updated prototype.
* stub-objc.c (objc_build_message_expr): Likewise.
In gcc/objc/:
2011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
* objc-act.c (objc_build_message_expr): Accept two arguments
instead of one so that callers can simply pass the arguments
without having to create a temporary chain to hold them.
In gcc/cp/:
2011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
* parser.c (cp_parser_objc_message_expression): Updated call
to objc_build_message_expr.
From-SVN: r172338
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/c-family/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/c-family/c-objc.h | 2 | ||||
-rw-r--r-- | gcc/c-family/stub-objc.c | 2 | ||||
-rw-r--r-- | gcc/c-parser.c | 5 | ||||
-rw-r--r-- | gcc/cp/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/cp/parser.c | 2 | ||||
-rw-r--r-- | gcc/objc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/objc/objc-act.c | 9 |
9 files changed, 31 insertions, 11 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 94d54ac..6d07d40 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2011-04-12 Nicola Pero <nicola.pero@meta-innovation.com> + + * c-parser.c (c_parser_initelt): Updated call to + objc_build_message_expr. + (c_parser_postfix_expression): Likewise. + 2011-04-12 Kai Tietz <ktietz@redhat.com> * config/i386/mingw32.h (TARGET_SUBTARGET_DEFAULT): Add diff --git a/gcc/c-family/ChangeLog b/gcc/c-family/ChangeLog index 6c50ab5..9fc2e22 100644 --- a/gcc/c-family/ChangeLog +++ b/gcc/c-family/ChangeLog @@ -1,3 +1,8 @@ +2011-04-12 Nicola Pero <nicola.pero@meta-innovation.com> + + * c-objc.h (objc_build_message_expr): Updated prototype. + * stub-objc.c (objc_build_message_expr): Likewise. + 2011-04-12 Martin Jambor <mjambor@suse.cz> * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead diff --git a/gcc/c-family/c-objc.h b/gcc/c-family/c-objc.h index e67eede..8f7bd62 100644 --- a/gcc/c-family/c-objc.h +++ b/gcc/c-family/c-objc.h @@ -53,7 +53,7 @@ extern tree objc_is_id (tree); extern void objc_declare_alias (tree, tree); extern void objc_declare_class (tree); extern void objc_declare_protocols (tree, tree); -extern tree objc_build_message_expr (tree); +extern tree objc_build_message_expr (tree, tree); extern tree objc_finish_message_expr (tree, tree, tree, tree*); extern tree objc_build_selector_expr (location_t, tree); extern tree objc_build_protocol_expr (tree); diff --git a/gcc/c-family/stub-objc.c b/gcc/c-family/stub-objc.c index e3aa98d..16f2931 100644 --- a/gcc/c-family/stub-objc.c +++ b/gcc/c-family/stub-objc.c @@ -258,7 +258,7 @@ objc_build_selector_expr (location_t ARG_UNUSED (loc), tree ARG_UNUSED (expr)) } tree -objc_build_message_expr (tree ARG_UNUSED (expr)) +objc_build_message_expr (tree ARG_UNUSED (receiver), tree ARG_UNUSED (args)) { return 0; } diff --git a/gcc/c-parser.c b/gcc/c-parser.c index 7542a58..0aefa42 100644 --- a/gcc/c-parser.c +++ b/gcc/c-parser.c @@ -3788,7 +3788,7 @@ c_parser_initelt (c_parser *parser, struct obstack * braced_init_obstack) c_parser_skip_until_found (parser, CPP_CLOSE_SQUARE, "expected %<]%>"); mexpr.value - = objc_build_message_expr (build_tree_list (rec, args)); + = objc_build_message_expr (rec, args); mexpr.original_code = ERROR_MARK; mexpr.original_type = NULL; /* Now parse and process the remainder of the @@ -6455,8 +6455,7 @@ c_parser_postfix_expression (c_parser *parser) args = c_parser_objc_message_args (parser); c_parser_skip_until_found (parser, CPP_CLOSE_SQUARE, "expected %<]%>"); - expr.value = objc_build_message_expr (build_tree_list (receiver, - args)); + expr.value = objc_build_message_expr (receiver, args); break; } /* Else fall through to report error. */ diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index f6dbddc..21a9377 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,8 @@ +2011-04-12 Nicola Pero <nicola.pero@meta-innovation.com> + + * parser.c (cp_parser_objc_message_expression): Updated call + to objc_build_message_expr. + 2011-04-12 Martin Jambor <mjambor@suse.cz> * class.c (cp_fold_obj_type_ref): Call cgraph_get_node instead of diff --git a/gcc/cp/parser.c b/gcc/cp/parser.c index 8414ab8..051c1c8 100644 --- a/gcc/cp/parser.c +++ b/gcc/cp/parser.c @@ -21289,7 +21289,7 @@ cp_parser_objc_message_expression (cp_parser* parser) messageargs = cp_parser_objc_message_args (parser); cp_parser_require (parser, CPP_CLOSE_SQUARE, RT_CLOSE_SQUARE); - return objc_build_message_expr (build_tree_list (receiver, messageargs)); + return objc_build_message_expr (receiver, messageargs); } /* Parse an objc-message-receiver. diff --git a/gcc/objc/ChangeLog b/gcc/objc/ChangeLog index 59bf50e..110de87 100644 --- a/gcc/objc/ChangeLog +++ b/gcc/objc/ChangeLog @@ -1,5 +1,11 @@ 2011-04-12 Nicola Pero <nicola.pero@meta-innovation.com> + * objc-act.c (objc_build_message_expr): Accept two arguments + instead of one so that callers can simply pass the arguments + without having to create a temporary chain to hold them. + +2011-04-12 Nicola Pero <nicola.pero@meta-innovation.com> + * objc-act.c (comp_proto_with_proto): Do not create and use inefficient temporary argument lists. Compare the arguments directly. (match_proto_with_proto): Removed; incorporated into diff --git a/gcc/objc/objc-act.c b/gcc/objc/objc-act.c index a0651f6..2f6613c 100644 --- a/gcc/objc/objc-act.c +++ b/gcc/objc/objc-act.c @@ -5026,14 +5026,13 @@ objc_message_selector (void) (*(<abstract_decl>(*)())_msgSuper)(receiver, selTransTbl[n], ...); */ tree -objc_build_message_expr (tree mess) +objc_build_message_expr (tree receiver, tree message_args) { - tree receiver = TREE_PURPOSE (mess); tree sel_name; #ifdef OBJCPLUS - tree args = TREE_PURPOSE (TREE_VALUE (mess)); + tree args = TREE_PURPOSE (message_args); #else - tree args = TREE_VALUE (mess); + tree args = message_args; #endif tree method_params = NULL_TREE; @@ -5057,7 +5056,7 @@ objc_build_message_expr (tree mess) /* Build the parameter list to give to the method. */ if (TREE_CODE (args) == TREE_LIST) #ifdef OBJCPLUS - method_params = chainon (args, TREE_VALUE (TREE_VALUE (mess))); + method_params = chainon (args, TREE_VALUE (message_args)); #else { tree chain = args, prev = NULL_TREE; |