<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><br><div><div>On Mar 12, 2013, at 7:55 AM, Jean-Daniel Dupas <<a href="mailto:devlists@shadowlab.org">devlists@shadowlab.org</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;"><br>Le 11 mars 2013 à 23:26, Fariborz Jahanian <<a href="mailto:fjahanian@apple.com">fjahanian@apple.com</a>> a écrit :<br><br><blockquote type="cite">Author: fjahanian<br>Date: Mon Mar 11 17:26:33 2013<br>New Revision: 176832<br><br>URL: <a href="http://llvm.org/viewvc/llvm-project?rev=176832&view=rev">http://llvm.org/viewvc/llvm-project?rev=176832&view=rev</a><br>Log:<br>Objective-C: When using super.prop, property should be<br>looked up the current class's super class.<br>// <a href="rdar://13349296">rdar://13349296</a><br><br>Modified:<br>  cfe/trunk/lib/Sema/SemaExprObjC.cpp<br>  cfe/trunk/test/Coverage/objc-language-features.inc<br>  cfe/trunk/test/SemaObjC/super-property-notation.m<br></blockquote><br>…<br><br><blockquote type="cite"><br>Modified: cfe/trunk/test/SemaObjC/super-property-notation.m<br>URL:<span class="Apple-converted-space"> </span><a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/test/SemaObjC/super-property-notation.m?rev=176832&r1=176831&r2=176832&view=diff">http://llvm.org/viewvc/llvm-project/cfe/trunk/test/SemaObjC/super-property-notation.m?rev=176832&r1=176831&r2=176832&view=diff</a><br>==============================================================================<br>--- cfe/trunk/test/SemaObjC/super-property-notation.m (original)<br>+++ cfe/trunk/test/SemaObjC/super-property-notation.m Mon Mar 11 17:26:33 2013<br>@@ -1,5 +1,4 @@<br>-// RUN: %clang_cc1 -fsyntax-only -verify %s<br>-// expected-no-diagnostics<br>+// RUN: %clang_cc1 -fsyntax-only -fobjc-default-synthesize-properties -verify %s<br><br>@interface B<br>+(int) classGetter;<br>@@ -29,3 +28,25 @@ void f0() {<br> int l2 = [A classGetter2];<br>}<br><br>+//<span class="Apple-converted-space"> </span><a href="rdar://13349296">rdar://13349296</a><br>+__attribute__((objc_root_class)) @interface ClassBase<span class="Apple-converted-space"> </span><br>+@property (nonatomic, retain) ClassBase * foo;<br>+@end<br>+<br>+@implementation ClassBase<span class="Apple-converted-space"> </span><br>+- (void) Meth:(ClassBase*)foo {<br>+  super.foo = foo; // expected-error {{'ClassBase' cannot use 'super' because it is a root class}}<br>+  [super setFoo:foo]; // expected-error {{'ClassBase' cannot use 'super' because it is a root class}}<br>+}<br>+@end<br>+<br>+@interface ClassDerived : ClassBase<span class="Apple-converted-space"> </span><br>+@property (nonatomic, retain) ClassDerived * foo;<br>+@end<br>+<br>+@implementation ClassDerived<br>+- (void) Meth:(ClassBase*)foo {<br>+  super.foo = foo; // issues compile warning<br></blockquote><br><br>If it issues a compile warning, why is there no expected-warning {{ }} here ?<span class="Apple-converted-space"> </span><br><br></div></blockquote><div><br></div>No. This was user's original complaint. I will remove user's comment. Thanks for noticing it.</div><div>- Fariborz</div><div><br><blockquote type="cite"><div style="letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;"><br><blockquote type="cite">+  [super setFoo:foo]; // works with no warning<br>+}<br>+@end<br></blockquote><br>-- Jean-Daniel</div></blockquote></div><br></body></html>