Swift compiler fails to compile 31entry dictionary with
| Originator: | iosdeveloperzone | ||
| Number: | rdar://18699199 | Date Originated: | 17-Oct-2014 |
| Status: | Open | Resolved: | |
| Product: | Developer Tools | Product Version: | Xcode 6.0 - 6.3 |
| Classification: | Reproducible: | Always |
Summary:
The swift compiler fails to compile the code below [this was attached in a project in the original radar] with "Expression too complex"
public enum SecurityProtocol
{
case FTP, FTPAccount, HTTP, IRC, NNTP, POP3, SMTP, SOCKS, IMAP, LDAP, AppleTalk, AFP, Telnet, SSH, FTPS, HTTPS, HTTPProxy, HTTPSProxy, FTPProxy, SMB, RTSP, RTSPProxy, DAAP, EPPC, IPP, NNTPS, LDAPS, TelnetS, IMAPS, IRCS, POP3S
let toRawValues = [ FTP: String(kSecAttrProtocolFTP),
FTPAccount: String(kSecAttrProtocolFTPAccount),
HTTP: String(kSecAttrProtocolHTTP),
IRC: String(kSecAttrProtocolIRC),
NNTP: String(kSecAttrProtocolNNTP),
POP3: String(kSecAttrProtocolPOP3),
SMTP: String(kSecAttrProtocolSMTP),
SOCKS: String(kSecAttrProtocolSOCKS),
IMAP: String(kSecAttrProtocolIMAP),
LDAP: String(kSecAttrProtocolLDAP),
AppleTalk: String(kSecAttrProtocolAppleTalk),
AFP: String(kSecAttrProtocolAFP),
Telnet: String(kSecAttrProtocolTelnet),
SSH: String(kSecAttrProtocolSSH),
FTPS: String(kSecAttrProtocolFTPS),
HTTPS: String(kSecAttrProtocolHTTPS),
HTTPProxy: String(kSecAttrProtocolHTTPProxy),
HTTPSProxy: String(kSecAttrProtocolHTTPSProxy),
FTPProxy: String(kSecAttrProtocolFTPProxy),
SMB: String(kSecAttrProtocolSMB),
RTSP: String(kSecAttrProtocolRTSP),
RTSPProxy: String(kSecAttrProtocolRTSPProxy),
DAAP: String(kSecAttrProtocolDAAP),
EPPC: String(kSecAttrProtocolEPPC),
IPP: String(kSecAttrProtocolIPP),
NNTPS: String(kSecAttrProtocolNNTPS),
LDAPS: String(kSecAttrProtocolLDAPS),
TelnetS: String(kSecAttrProtocolTelnetS),
IMAPS: String(kSecAttrProtocolIMAPS),
IRCS: String(kSecAttrProtocolIRCS),
POP3S: String(kSecAttrProtocolPOP3S) ]
}
Steps to Reproduce:
Attempt to compile the attached project in Xcode 6.1 Build 6A1052c or Build 6A1042b
Expected Results:
The file should compile. 31 entries is hardly huge (in fact it will fail with 12).
Actual Results:
The file fails to compile with an expression too complex error.
Version:
Xcode 6.1 6A1052c
Xcode 6.1 6A1042b
Xcode 6.2 6C121
Xcode 6.3 6D520o
Mac OS X 10.9.5 13F34
Comments
Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!