Xcode-beta (7A192o):
| Originator: | konstantin.koval1 | ||
| Number: | rdar://22415197 | Date Originated: | 25-Aug-2015 08:40 AM |
| Status: | Open | Resolved: | |
| Product: | Developer Tools | Product Version: | Xcode 7-beta 6 (7A192o) |
| Classification: | Crash/Hang/Data Loss | Reproducible: | Always |
Summary: public subscript (subRange: Range<Int>) -> ArraySlice<Element> is not working. This is from Xcode 7 beta 6 release notes "For consistency and better composition of generic code, ArraySlice indices are no longer always zero- based but map directly onto the indices of the collection they are slicing and maintain that mapping even after mutations. Before: var a = Array(0..<10) var s = a[5..<10] s.indices s[0] = 111 s s.removeFirst() s.indices Try to run this code, it doesn't work. Steps to Reproduce: Make a playground, run the code. Expected Results: It should work Actual Results: fatal error: ArraySlice index out of range Notes: Playgrounds is attached
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!