mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Ensure that #if stripping for postfix expressions works in interface generation
Test case from rdar://117491193
This commit is contained in:
@@ -329,3 +329,17 @@ public class HasDefaultDeinit {
|
||||
// CHECK: [[OBJC]]deinit{{$}}
|
||||
// CHECK-NEXT: }
|
||||
}
|
||||
|
||||
// CHECK: public func testInlinableTextRemovesPostfix()
|
||||
@inlinable public func testInlinableTextRemovesPostfix() {
|
||||
// FROMSOURCE: "foobar"
|
||||
// FROMSOURCE-NOT: .debugDescription
|
||||
// FROMSOURCE: .description
|
||||
// FROMSOURCE-NEXT: }
|
||||
_ = "foobar"
|
||||
#if DEBUG
|
||||
.debugDescription
|
||||
#else
|
||||
.description
|
||||
#endif
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user