Skip to content

Commit ece3e18

Browse files
committed
Remove uses of the phrase "in Rust"
This is mentioned specifically in the style guide.
1 parent 5c4a7a6 commit ece3e18

6 files changed

+7
-7
lines changed

Diff for: src/comments.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
3535
## Non-doc comments
3636

37-
Comments in Rust code follow the general C++ style of line (`//`) and
37+
Comments follow the general C++ style of line (`//`) and
3838
block (`/* ... */`) comment forms. Nested block comments are supported.
3939

4040
Non-doc comments are interpreted as a form of whitespace.

Diff for: src/interior-mutability.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ mutability if its internal state can be changed through a [shared reference] to
66
it. This goes against the usual [requirement][ub] that the value pointed to by a
77
shared reference is not mutated.
88

9-
[`std::cell::UnsafeCell<T>`] type is the only allowed way in Rust to disable
9+
[`std::cell::UnsafeCell<T>`] type is the only allowed way to disable
1010
this requirement. When `UnsafeCell<T>` is immutably aliased, it is still safe to
1111
mutate, or obtain a mutable reference to, the `T` it contains. As with all
1212
other types, it is undefined behavior to have multiple `&mut UnsafeCell<T>`

Diff for: src/items/functions.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ is equivalent to:
175175
extern "Rust" fn foo() {}
176176
```
177177

178-
Functions in Rust can be called by foreign code, and using an ABI that
178+
Functions can be called by foreign code, and using an ABI that
179179
differs from Rust allows, for example, to provide functions that can be
180180
called from other programming languages like C:
181181

Diff for: src/statements-and-expressions.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,5 @@ each other kind of expression, and rules for evaluation of expressions involve
77
specifying both the value produced by the expression and the order in which its
88
sub-expressions are themselves evaluated.
99

10-
In contrast, statements in Rust serve _mostly_ to contain and explicitly
10+
In contrast, statements serve _mostly_ to contain and explicitly
1111
sequence expression evaluation.

Diff for: src/types/pointer.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Pointer types
22

3-
All pointers in Rust are explicit first-class values.
3+
All pointers are explicit first-class values.
44
They can be moved or copied, stored into data structs, and returned from functions.
55

66
## References (`&` and `&mut`)
@@ -38,7 +38,7 @@ For example `*const i32` means a raw pointer to a 32-bit integer.
3838
Copying or dropping a raw pointer has no effect on the lifecycle of any other value.
3939
Dereferencing a raw pointer is an [`unsafe` operation].
4040
This can also be used to convert a raw pointer to a reference by reborrowing it (`&*` or `&mut *`).
41-
Raw pointers are generally discouraged in Rust code;
41+
Raw pointers are generally discouraged;
4242
they exist to support interoperability with foreign code, and writing performance-critical or low-level functions.
4343

4444
When comparing raw pointers they are compared by their address, rather than by what they point to.

Diff for: src/visibility-and-privacy.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ of an item to see whether it should be allowed or not. This is where privacy
2222
warnings are generated, or otherwise "you used a private item of another module
2323
and weren't allowed to."
2424

25-
By default, everything in Rust is *private*, with two exceptions: Associated
25+
By default, everything is *private*, with two exceptions: Associated
2626
items in a `pub` Trait are public by default; Enum variants
2727
in a `pub` enum are also public by default. When an item is declared as `pub`,
2828
it can be thought of as being accessible to the outside world. For example:

0 commit comments

Comments
 (0)