|
1 |
| -// rdar://13723332 Crash on -emit-sil with no input files |
2 |
| -// RUN: not %target-swift-frontend -emit-sil 2>&1 | %FileCheck -check-prefix=NO_FILES %s |
3 |
| -// RUN: not %target-swift-frontend -emit-sil -parse-as-library 2>&1 | %FileCheck -check-prefix=NO_FILES %s |
4 |
| -// NO_FILES: this mode requires at least one input file |
5 |
| - |
6 |
| -// RUN: not %target-swift-frontend -parse-sil -emit-sil 2>&1 | %FileCheck -check-prefix=SIL_FILES %s |
7 |
| -// SIL_FILES: this mode requires a single input file |
8 |
| - |
9 |
| -// RUN: not %target-swift-frontend -parse-sil -emit-sil %s %s 2>&1 | %FileCheck -check-prefix=DUPLICATE_FILES %s |
10 |
| -// RUN: not %target-swift-frontend -parse-sil -emit-sil %s %S/../Inputs/empty.swift 2>&1 | %FileCheck -check-prefix=SIL_FILES %s |
11 |
| -// DUPLICATE_FILES: duplicate input file 'SOURCE_DIR/test/Driver/options.swift' |
12 |
| - |
13 |
| - |
14 |
| -// RUN: not %target-swift-frontend -emit-silgen -parse-as-library %S/Inputs/invalid-module-name.swift 2>&1 | %FileCheck -check-prefix=INVALID_MODULE_NAME %s |
15 |
| -// INVALID_MODULE_NAME: error: module name "invalid-module-name" is not a valid identifier; use -module-name flag to specify an alternate name |
16 |
| - |
17 |
| -// RUN: not %target-swift-frontend -emit-silgen -parse-as-library %S/Inputs/invalid.module.name.swift 2>&1 | %FileCheck -check-prefix=INVALID_MODULE_NAME2 %s |
18 |
| -// INVALID_MODULE_NAME2: error: module name "invalid.module.name" is not a valid identifier; use -module-name flag to specify an alternate name |
19 |
| - |
20 |
| -// RUN: not %target-swift-frontend -emit-silgen -parse-as-library %S/Inputs/invalid-module-name.swift -module-name still-invalid 2>&1 | %FileCheck -check-prefix=STILL_INVALID %s |
21 |
| -// STILL_INVALID: error: module name "still-invalid" is not a valid identifier{{$}} |
22 |
| - |
23 |
| -// RUN: not %target-swiftc_driver -emit-silgen -parse-as-library %s -module-name "Swift" 2>&1 | %FileCheck -check-prefix=STDLIB_MODULE %s |
| 1 | +// RUN: not %swiftc_driver -emit-silgen -parse-as-library %s -module-name "Swift" 2>&1 | %FileCheck -check-prefix=STDLIB_MODULE %s |
24 | 2 | // RUN: %target-swiftc_driver -emit-silgen -parse-as-library %s -module-name "Swift" -parse-stdlib -###
|
25 | 3 | // STDLIB_MODULE: error: module name "Swift" is reserved for the standard library{{$}}
|
26 | 4 |
|
27 |
| -// RUN: not %target-swift-frontend -typecheck -emit-module %s 2>&1 | %FileCheck -check-prefix=PARSE_NO_MODULE %s |
28 |
| -// PARSE_NO_MODULE: error: this mode does not support emitting modules{{$}} |
29 |
| - |
30 |
| -// RUN: not %target-swift-frontend -parse -emit-dependencies %s 2>&1 | %FileCheck -check-prefix=PARSE_NO_DEPS %s |
31 |
| -// PARSE_NO_DEPS: error: this mode does not support emitting dependency files{{$}} |
32 |
| -// RUN: not %target-swift-frontend -dump-ast -emit-dependencies %s 2>&1 | %FileCheck -check-prefix=DUMP_NO_DEPS %s |
33 |
| -// DUMP_NO_DEPS: error: this mode does not support emitting dependency files{{$}} |
34 |
| - |
35 |
| -// RUN: not %target-swift-frontend -parse -emit-reference-dependencies %s 2>&1 | %FileCheck -check-prefix=PARSE_NO_REFERENCE_DEPS %s |
36 |
| -// PARSE_NO_REFERENCE_DEPS: error: this mode does not support emitting reference dependency files{{$}} |
37 |
| -// RUN: not %target-swift-frontend -dump-ast -emit-reference-dependencies %s 2>&1 | %FileCheck -check-prefix=DUMP_NO_REFERENCE_DEPS %s |
38 |
| -// DUMP_NO_REFERENCE_DEPS: error: this mode does not support emitting reference dependency files{{$}} |
39 |
| -// RUN: not %target-swift-frontend -resolve-imports -emit-reference-dependencies %s 2>&1 | %FileCheck -check-prefix=RESOLVE_IMPORTS_NO_REFERENCE_DEPS %s |
40 |
| -// RESOLVE_IMPORTS_NO_REFERENCE_DEPS: error: this mode does not support emitting reference dependency files{{$}} |
41 |
| - |
42 |
| -// RUN: not %target-swift-frontend -parse -emit-objc-header %s 2>&1 | %FileCheck -check-prefix=PARSE_NO_OBJC_HEADER %s |
43 |
| -// PARSE_NO_OBJC_HEADER: error: this mode does not support emitting Objective-C headers{{$}} |
44 |
| -// RUN: not %target-swift-frontend -dump-ast -emit-objc-header %s 2>&1 | %FileCheck -check-prefix=DUMP_NO_OBJC_HEADER %s |
45 |
| -// DUMP_NO_OBJC_HEADER: error: this mode does not support emitting Objective-C headers{{$}} |
46 |
| -// RUN: not %target-swift-frontend -resolve-imports -emit-objc-header %s 2>&1 | %FileCheck -check-prefix=RESOLVE_IMPORTS_NO_OBJC_HEADER %s |
47 |
| -// RESOLVE_IMPORTS_NO_OBJC_HEADER: error: this mode does not support emitting Objective-C headers{{$}} |
48 |
| - |
49 |
| -// Should not fail with non-zero exit code. |
50 |
| -// RUN: %target-swift-frontend -emit-silgen %S/Inputs/invalid-module-name.swift > /dev/null |
51 |
| -// RUN: %target-swift-frontend -emit-silgen -parse-as-library %S/Inputs/invalid-module-name.swift -module-name foo > /dev/null |
52 |
| -// RUN: %target-swift-frontend -typecheck -parse-as-library %S/Inputs/invalid-module-name.swift -module-name foo |
53 |
| - |
54 | 5 | // RUN: not %swiftc_driver -crazy-option-that-does-not-exist %s 2>&1 | %FileCheck -check-prefix=INVALID_OPTION %s
|
55 | 6 | // RUN: not %swift_driver -crazy-option-that-does-not-exist 2>&1 | %FileCheck -check-prefix=INVALID_OPTION %s
|
56 | 7 | // INVALID_OPTION: error: unknown argument: '-crazy-option-that-does-not-exist'
|
|
0 commit comments