   return 0 // expected-warning {{will never be executed}}
 }
 
+// Work-around <rdar://problem/17687851> by ensuring there is
+// something that appears to be user code in unreachable blocks.
+func userCode() {}
 
 func whileTrue() {
   var x = 0
   while true { // expected-note {{always evaluates to true}}
     x++
   }
-  x-- // expected-warning {{will never be executed}}
+  userCode() // expected-warning {{will never be executed}}
 }
 
 func whileTrueReachable(v: Int) -> () {

    }
    x++
  }
  x--  // expected-warning {{will never be executed}}
}

func unreachableBranch() -> Int {

  var cond: X = .Two
  switch cond { // expected-warning {{switch condition evaluates to a constant}}
  case .One:
    userCode() // expected-note {{will never be executed}}
  case .Two:
    x--  
  case .Three:
