diff options
| author | Kevin Yap <me@kevinyap.ca> | 2015-01-08 16:52:50 -0800 |
|---|---|---|
| committer | Kevin Yap <me@kevinyap.ca> | 2015-01-08 17:15:26 -0800 |
| commit | 8f61814641c0fbbb929c8a04658d4ea819b4db51 (patch) | |
| tree | 192edd3dd39bad177fdca131f104b039ec861985 /src/doc/trpl/method-syntax.md | |
| parent | 6354d60ede5e2a7e60fa46f85243efd8dbe89711 (diff) | |
| download | rust-8f61814641c0fbbb929c8a04658d4ea819b4db51.tar.gz rust-8f61814641c0fbbb929c8a04658d4ea819b4db51.zip | |
Standardize punctuation & formatting of TRPL
This commit is an attempt to standardize the use of punctuation and formatting in "The Rust Programming Language" as discussed in #19823. - Convert bold text to italicized textcwhen referring to terminology. - Convert single-quoted text to italicized or double-quoted text, depending on context. - Use double quotes only in the case of scare quotes or quotations.
Diffstat (limited to 'src/doc/trpl/method-syntax.md')
| -rw-r--r-- | src/doc/trpl/method-syntax.md | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/doc/trpl/method-syntax.md b/src/doc/trpl/method-syntax.md index 54e9cdf5191..3d8de00991c 100644 --- a/src/doc/trpl/method-syntax.md +++ b/src/doc/trpl/method-syntax.md @@ -7,8 +7,8 @@ can be awkward. Consider this code: baz(bar(foo(x))); ``` -We would read this left-to right, and so we see 'baz bar foo.' But this isn't the -order that the functions would get called in, that's inside-out: 'foo bar baz.' +We would read this left-to right, and so we see "baz bar foo." But this isn't the +order that the functions would get called in, that's inside-out: "foo bar baz." Wouldn't it be nice if we could do this instead? ```{rust,ignore} @@ -16,7 +16,7 @@ x.foo().bar().baz(); ``` Luckily, as you may have guessed with the leading question, you can! Rust provides -the ability to use this **method call syntax** via the `impl` keyword. +the ability to use this *method call syntax* via the `impl` keyword. Here's how it works: @@ -82,7 +82,7 @@ fn main() { } ``` -This **static method** builds a new `Circle` for us. Note that static methods +This *static method* builds a new `Circle` for us. Note that static methods are called with the `Struct::method()` syntax, rather than the `ref.method()` syntax. |
