-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
24 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
// RUN: compiler -h 2>&1 | filecheck %s | ||
|
||
// CHECK: Usage: | ||
// CHECK-NEXT: your-compiler [options] <source_file> | ||
// CHECK-NEXT: | ||
// CHECK-NEXT: Options: | ||
// CHECK-NEXT: -h display this message | ||
// CHECK-NEXT: -o <file> write executable to <file> | ||
// CHECK-NEXT: -ast-dump print the abstract syntax tree | ||
// CHECK-NEXT: -res-dump print the resolved syntax tree | ||
// CHECK-NEXT: -llvm-dump print the llvm module | ||
// CHECK-NEXT: -cfg-dump print the control flow graph |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
// RUN: (compiler src1 src2 || true) 2>&1 | filecheck %s | ||
// CHECK: error: unexpected argument 'src2' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
// RUN: (compiler || true) 2>&1 | filecheck %s | ||
// CHECK: error: no source file specified |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
// RUN: (compiler ./non_existent_source || true) 2>&1 | filecheck %s | ||
// CHECK: error: failed to open './non_existent_source' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
// RUN: compiler %s || test $? -eq 1 | ||
parser error |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
// RUN: compiler %s || test $? -eq 1 | ||
fn main(): semaError {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
// RUN: (compiler -unknown || true) 2>&1 | filecheck %s | ||
// CHECK: error: unexpected option '-unknown' |