Swift 3.0 migrator crashes on array of option sets

Originator:keithbsmiley
Number:rdar://26886803 Date Originated:19-Jun-2016 23:18
Status:Open Resolved:
Product:Developer Tools Product Version:Xcode 8 beta 1
Classification:Other Bug Reproducible:Always
 
Summary:
When migrating our codebase from Swift 2.2 -> Swift 3.0 we noticed a crash when you defined an array of option sets.

Steps to Reproduce:
1. Define the array:

```
let states: [UIControlState] = [.Normal, .Highlighted, .Disabled, .Selected, [.Selected, .Highlighted]]
```

2. Migrate the code

Expected Results:
In this case `.Normal` should be replaced with `[]` since the default case was removed in Swift 3

Actual Results:
The migrator crashes.

Version:
Xcode 8 beta 1

Notes:
From the discussion in the labs it sounds like the issue is option sets being contained in an array, which has the same syntax as an option set literal.

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!