Commit efa39e99 by Devang Patel Committed by Devang Patel

objc-act.c (adjust_type_for_id_default): Fix my previous patch.


2002-07-09 Devang Patel <dpatel@apple.com>
        * objc/objc-act.c (adjust_type_for_id_default): Fix my previous patch.
        Do not allow ObjC objects as a parameter type for Objective-C methods.
        My previous patch restricted  'struct' also.

From-SVN: r55348
parent cd98faa1
2002-07-09 Devang Patel <dpatel@apple.com>
* objc/objc-act.c (adjust_type_for_id_default): Fix my previous patch.
Do not allow ObjC objects as a parameter type for Objective-C methods.
My previous patch restricted 'struct' also.
2002-07-09 Neil Booth <neil@daikokuya.co.uk>
* cpperror.c (cpp_error): Default to directive_line within
......
......@@ -4465,7 +4465,7 @@ adjust_type_for_id_default (type)
chain;
chain = TREE_CHAIN (chain))
{
if (TREE_CODE (TREE_VALUE (chain)) == RECORD_TYPE
if (TYPED_OBJECT (TREE_VALUE (chain))
&& !(TREE_VALUE (type)
&& TREE_CODE (TREE_VALUE (type)) == INDIRECT_REF))
error ("can not use an object as parameter to a method\n");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment