[llvm-bugs] [Bug 28058] New: Incorrect compiler error

via llvm-bugs llvm-bugs at lists.llvm.org
Wed Jun 8 15:09:24 PDT 2016


https://llvm.org/bugs/show_bug.cgi?id=28058

            Bug ID: 28058
           Summary: Incorrect compiler error
           Product: new-bugs
           Version: unspecified
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: rolfbjarne at gmail.com
                CC: llvm-bugs at lists.llvm.org
    Classification: Unclassified

Created attachment 16496
  --> https://llvm.org/bugs/attachment.cgi?id=16496&action=edit
Test case

Compiling the attached test code with:

/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang
-isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS9.3.sdk
-arch armv7 bug.m

> bug.m:10:17: warning: 'NSObject' may not respond to 'initWithCoder:'
>                 return [super initWithCoder:p0];
>                         ~~~~~ ^
> bug.m:10:17: error: 'initWithCoder:' is unavailable
> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS9.3.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIActivityViewController.h:23:1: note: 'initWithCoder:' has been explicitly marked unavailable here
> - (nullable instancetype)initWithCoder:(NSCoder *)aDecoder NS_UNAVAILABLE;
> ^
> 1 warning and 1 error generated.> 

I'm not sure if the code should actually show an error or not, but I am sure
there's nothing related to UIActivityViewController.h at all in the code
snippet (so if the code is invalid, the error message itself is still
incorrect).

> /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang --version
Apple LLVM version 7.3.0 (clang-703.0.29)
Target: x86_64-apple-darwin15.5.0
Thread model: posix
InstalledDir:
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
(from Xcode 7.3)

-- 
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/20160608/575fbd14/attachment-0001.html>


More information about the llvm-bugs mailing list