mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
The code goes into its own sub-tree under 'tools' but tests go under 'test', so that running 'check-swift' will also run all the SourceKit tests. SourceKit is disabled on non-darwin platforms.
17 lines
679 B
Swift
17 lines
679 B
Swift
|
|
func test(b : BaseInHead) {
|
|
b.doIt(0);
|
|
}
|
|
|
|
// RUN: %swift -parse %s %mcp_opt -module-name Mixed -import-objc-header %S/Inputs/header.h 2> %t.diags
|
|
// RUN: FileCheck -input-file %t.diags %s -check-prefix=DIAG
|
|
// DIAG: warning: using the result of an assignment
|
|
|
|
// RUN: %sourcekitd-test -req=cursor -pos=3:7 %s -- %s %mcp_opt -module-name Mixed -import-objc-header %S/Inputs/header.h | FileCheck %s
|
|
|
|
// CHECK: source.lang.swift.ref.function.method.instance ({{.*}}Inputs/header.h:4:9-4:23)
|
|
// CHECK: doIt(_:)
|
|
// CHECK: c:objc(cs)BaseInHead(im)doIt:
|
|
// CHECK: BaseInHead -> (Int32) -> Void
|
|
// CHECK: <Declaration>func doIt(arg: <Type usr="s:Vs5Int32">Int32</Type>)</Declaration>
|