From 16e8f45ab86dda7aeee74cfa89f15d2355ba5c0d Mon Sep 17 00:00:00 2001 From: katopz Date: Tue, 11 Oct 2022 09:43:03 +0700 Subject: [PATCH] fix: unnecessary space --- en/src/basic-types/char-bool-unit.md | 8 ++++---- en/src/generics-traits/traits.md | 2 +- en/src/ownership/ownership.md | 2 +- zh-CN/src/basic-types/char-bool-unit.md | 8 ++++---- zh-CN/src/generics-traits/traits.md | 2 +- zh-CN/src/ownership/ownership.md | 2 +- 6 files changed, 12 insertions(+), 12 deletions(-) diff --git a/en/src/basic-types/char-bool-unit.md b/en/src/basic-types/char-bool-unit.md index 87e0223..cb059d8 100644 --- a/en/src/basic-types/char-bool-unit.md +++ b/en/src/basic-types/char-bool-unit.md @@ -2,7 +2,7 @@ ### Char 1. 🌟 -```rust, editable +```rust,editable // Make it work use std::mem::size_of_val; @@ -18,7 +18,7 @@ fn main() { ``` 2. 🌟 -```rust, editable +```rust,editable // Make it work fn main() { @@ -33,7 +33,7 @@ fn print_char(c : char) { ### Bool 3. 🌟 -```rust, editable +```rust,editable // Make println! work fn main() { @@ -47,7 +47,7 @@ fn main() { ``` 4. 🌟 -```rust, editable +```rust,editable // Make it work fn main() { diff --git a/en/src/generics-traits/traits.md b/en/src/generics-traits/traits.md index 57a861d..938d852 100644 --- a/en/src/generics-traits/traits.md +++ b/en/src/generics-traits/traits.md @@ -335,7 +335,7 @@ The `impl Trait` syntax works for straightforward cases but is actually syntax s When working with generics, the type parameters often must use traits as bounds to stipulate what functionality a type implements. 7. 🌟🌟 -```rust, editable +```rust,editable fn main() { assert_eq!(sum(1, 2), 3); } diff --git a/en/src/ownership/ownership.md b/en/src/ownership/ownership.md index fe94646..01bd390 100644 --- a/en/src/ownership/ownership.md +++ b/en/src/ownership/ownership.md @@ -62,7 +62,7 @@ fn print_str(s: String) { ``` 5. 🌟🌟 -```rust, editable +```rust,editable // Don't use clone ,use copy instead fn main() { let x = (1, 2, (), "hello".to_string()); diff --git a/zh-CN/src/basic-types/char-bool-unit.md b/zh-CN/src/basic-types/char-bool-unit.md index 3c055e8..4bfdcca 100644 --- a/zh-CN/src/basic-types/char-bool-unit.md +++ b/zh-CN/src/basic-types/char-bool-unit.md @@ -2,7 +2,7 @@ ### 字符 1. 🌟 -```rust, editable +```rust,editable // 修改2处 `assert_eq!` 让代码工作 use std::mem::size_of_val; @@ -18,7 +18,7 @@ fn main() { ``` 2. 🌟 -```rust, editable +```rust,editable // 修改一行让代码正常打印 fn main() { let c1 = "中"; @@ -32,7 +32,7 @@ fn print_char(c : char) { ### 布尔 3. 🌟 -```rust, editable +```rust,editable // 使成功打印 fn main() { @@ -46,7 +46,7 @@ fn main() { ``` 4. 🌟 -```rust, editable +```rust,editable fn main() { let f = true; diff --git a/zh-CN/src/generics-traits/traits.md b/zh-CN/src/generics-traits/traits.md index ebe003b..26fb453 100644 --- a/zh-CN/src/generics-traits/traits.md +++ b/zh-CN/src/generics-traits/traits.md @@ -333,7 +333,7 @@ fn main() { 当使用泛型参数时,我们往往需要为该参数指定特定的行为,这种指定方式就是通过特征约束来实现的。 7. 🌟🌟 -```rust, editable +```rust,editable fn main() { assert_eq!(sum(1, 2), 3); } diff --git a/zh-CN/src/ownership/ownership.md b/zh-CN/src/ownership/ownership.md index 3b12d00..9c0b1cf 100644 --- a/zh-CN/src/ownership/ownership.md +++ b/zh-CN/src/ownership/ownership.md @@ -63,7 +63,7 @@ fn print_str(s: String) { ``` 5. 🌟🌟 -```rust, editable +```rust,editable // 不要使用 clone,使用 copy 的方式替代 fn main() { let x = (1, 2, (), "hello".to_string());