diff options
author | Nicola Pero <nicola.pero@meta-innovation.com> | 2011-06-07 20:47:12 +0000 |
---|---|---|
committer | Nicola Pero <nicola@gcc.gnu.org> | 2011-06-07 20:47:12 +0000 |
commit | ac07a61dda48ef1d9564d9a40d04f0e938bdd888 (patch) | |
tree | 1e1393cb20beed8310971be7718df9b25b34e078 /gcc/testsuite/objc-obj-c++-shared/runtime.h | |
parent | 80e4b9e501e4e702f1c32287c1ff57ca84054a7c (diff) | |
download | gcc-ac07a61dda48ef1d9564d9a40d04f0e938bdd888.zip gcc-ac07a61dda48ef1d9564d9a40d04f0e938bdd888.tar.gz gcc-ac07a61dda48ef1d9564d9a40d04f0e938bdd888.tar.bz2 |
In gcc/testsuite/: 2011-06-07 Nicola Pero <nicola.pero@meta-innovation.com> Iain Sandoe <iains@gcc.gnu.org>
In gcc/testsuite/:
2011-06-07 Nicola Pero <nicola.pero@meta-innovation.com>
Iain Sandoe <iains@gcc.gnu.org>
* objc-obj-c++-shared/runtime.h (protocol_getMethodDescription):
Added code to deal with the case when [Protocol
-descriptionForInstanceMethod:] or [Protocol
-descriptionForClassMethod:] returns NULL.
2011-06-07 Nicola Pero <nicola.pero@meta-innovation.com>
Iain Sandoe <iains@gcc.gnu.org>
* objc-obj-c++-shared/TestsuiteObject.h ([-free]): Return 'id'.
* objc-obj-c++-shared/TestsuiteObject.m ([-free]): Return 'id'.
Added cast.
Co-Authored-By: Iain Sandoe <iains@gcc.gnu.org>
From-SVN: r174766
Diffstat (limited to 'gcc/testsuite/objc-obj-c++-shared/runtime.h')
-rw-r--r-- | gcc/testsuite/objc-obj-c++-shared/runtime.h | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/gcc/testsuite/objc-obj-c++-shared/runtime.h b/gcc/testsuite/objc-obj-c++-shared/runtime.h index bdc2bff..4d7d1c3 100644 --- a/gcc/testsuite/objc-obj-c++-shared/runtime.h +++ b/gcc/testsuite/objc-obj-c++-shared/runtime.h @@ -93,14 +93,16 @@ struct objc_method_description protocol_getMethodDescription (Protocol *protocol struct objc_method_description result; if (instanceMethod) - { - tmp = [protocol descriptionForInstanceMethod: selector]; - result = *tmp; - } + tmp = [protocol descriptionForInstanceMethod: selector]; + else + tmp = [protocol descriptionForClassMethod: selector]; + + if (tmp) + result = *tmp; else { - tmp = [protocol descriptionForClassMethod: selector]; - result = *tmp; + result.name = (SEL)0; + result.types = (char *)0; } return result; |