[LLVMbugs] [Bug 16161] New: Warn about incomplete implementation of declared properties already declared in base class

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Tue May 28 04:29:36 PDT 2013


http://llvm.org/bugs/show_bug.cgi?id=16161

            Bug ID: 16161
           Summary: Warn about incomplete implementation of declared
                    properties already declared in base class
           Product: clang
           Version: 3.1
          Hardware: Macintosh
                OS: MacOS X
            Status: NEW
          Severity: normal
          Priority: P
         Component: Frontend
          Assignee: unassignedclangbugs at nondot.org
          Reporter: negm-awad at cocoading.de
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

A. Steps to reproduce
1. Define a base class with a read-only property
@interface BaseClass : NSObject
@property (readonly) id property;
@end

2. Define a protocol that contains a read-write property with the same name
@protocol Protocol
@property (readwrite) id property;
@end

3. Derive from BaseClass importing the protocol
@interface DerivedClass : BaseClass <Protocol>
@end

4. Autosynthesize that property (I know, that's illegal, look below)
@implementation DerivedClass
@end

B. Existing behaviour
Step 4 is illegal. Without the readonly property in the base class, I will get
a warning:
Auto property synthesis will not synthesize property declared in a protocol.
(Documented behavior)
With the readonly property in the base class, I neither get a warning about
auto synthesize nor about incomplete implementation.

C. Expected behavior
One of the warnings above.

Thank you!

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20130528/30148b7e/attachment.html>


More information about the llvm-bugs mailing list