[LLVMbugs] [Bug 11244] New: Objective-C - readonly attribute in property declaration

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Thu Oct 27 00:16:47 PDT 2011


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

           Summary: Objective-C - readonly attribute in property
                    declaration
           Product: new-bugs
           Version: unspecified
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: muthuveerappan.al at gmail.com
                CC: llvmbugs at cs.uiuc.edu


Created an attachment (id=7537)
 --> (http://llvm.org/bugs/attachment.cgi?id=7537)
sample objective-c program to explain the bug

As per Objective-C documentation, readonly attribute can't be used in a
property declaration along with the setter attribute.

Documentation 
==========
Quoted from the document The Objective‐C Programming Language (page 71)

"If you specify that a property is readonly and also specify a setter with
setter=, you get a compiler warning."

Sample Program
==========
see attachment for small program in objective-c explaining the problem

Actual behavior:
==========
Clang doesn't throw an error in line 20 in the attached program

Expected Behavior
===========
Clang should throw an error stating that "setter cannot be specified for a
'readonly' property ‘n1’"

Pls can you pls fix this, let me know if you need more information.

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



More information about the llvm-bugs mailing list