Skip to content

Commit 85f3d71

Browse files
committed
feat: rename "example" to "examples", and rename "example.rs" to "basic_math.rs"
1 parent 95b6d19 commit 85f3d71

File tree

5 files changed

+6
-6
lines changed

5 files changed

+6
-6
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ The project is at very early stage. Most of the code is not implemented yet.
1414
In the root directory of the project, run the following command:
1515

1616
```bash
17-
./y rustc example/example.rs
18-
./build/example
17+
./y rustc examples/basic_math.rs
18+
./build/basic_math
1919
```
2020

2121
The usage of `./y` can be viewed from `./y help`.

bootstrap/src/fmt.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ impl Run for FmtCommand {
2323
.args(["--manifest-path", "crates/Cargo.toml"])
2424
.arg("--all"),
2525
);
26-
for file in glob("example/**/*.rs").unwrap() {
26+
for file in glob("examples/**/*.rs").unwrap() {
2727
self.perform(Command::new("rustfmt").args(["--edition", "2021"]).arg(file.unwrap()));
2828
}
2929
for file in glob("tests/**/*.rs").unwrap() {

bootstrap/src/test.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ impl TestCommand {
5858
let mut result = vec![];
5959

6060
// Examples
61-
for case in glob("example/*.rs").unwrap() {
61+
for case in glob("examples/*.rs").unwrap() {
6262
let case = case.unwrap();
6363
let filename = case.file_stem().unwrap();
6464
if filename == "mini_core" {
@@ -74,8 +74,8 @@ impl TestCommand {
7474
);
7575
continue;
7676
}
77-
let name = format!("example/{}", filename.to_string_lossy());
78-
let output = manifest.out_dir.join("example").join(filename);
77+
let name = format!("examples/{}", filename.to_string_lossy());
78+
let output = manifest.out_dir.join("examples").join(filename);
7979
result.push(TestCase { name, source: case, output, test: TestType::Compile })
8080
}
8181

File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)