Skip to content

Commit a8d7349

Browse files
committed
Add regression test to close #59572
1 parent 15bd9a4 commit a8d7349

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
// RUN: %target-swift-emit-ir %s
2+
3+
func foo<T: RawRepresentable>(src: Any, target: inout T) where T.RawValue == UInt {
4+
if let x = src as? UInt, let x = T(rawValue: x) {
5+
target = x
6+
}
7+
}

0 commit comments

Comments
 (0)