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

             Bug #: 11292
           Summary: Objective-C - incompatible pointer type assignment not
                    detected when used with init method
           Product: new-bugs
           Version: unspecified
          Platform: Macintosh
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
        AssignedTo: [email protected]
        ReportedBy: [email protected]
                CC: [email protected]
    Classification: Unclassified


Created attachment 7571
  --> http://llvm.org/bugs/attachment.cgi?id=7571
example showing incompatible pointer type assignment not detected when used
with init method

Objective-C - incompatible pointer type assignment not detected when used with
init method

When an init method returns a pointer type and when that pointer is assigned to
another incompatible pointer variable, the compiler doesn't throw an error /
warning

Note - When tested with a method that doesn't have the prefix as "init",
compiler manages to detect the error / warning

Actual Behavior
============
The compiler doesn't throw an error / warning, when pointer type returned by an
init method is assigned to an incompatible variable.

Expected Behavior
==============
The compiler should throw an error / warning, when pointer type returned by an
init method is assigned to an incompatible variable.

Example (Sample Objective-C program) 
=================================
Sample program showing incompatible pointer assignment by init method is
attached

-- 
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.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs

Reply via email to