diff options
| author | bors <bors@rust-lang.org> | 2015-10-08 22:40:50 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2015-10-08 22:40:50 +0000 |
| commit | d0cae14f6627e2ad2b50998755eeb818aad750ca (patch) | |
| tree | 37db2fd58d85f39c7154c96f6dffc4b2f341dfe5 /src/libsyntax | |
| parent | 11eda66df859f53754788044476af753a012332f (diff) | |
| parent | 4b308b44e1d8204702f6912dda4dfc404aa2a87d (diff) | |
| download | rust-d0cae14f6627e2ad2b50998755eeb818aad750ca.tar.gz rust-d0cae14f6627e2ad2b50998755eeb818aad750ca.zip | |
Auto merge of #28900 - cristicbz:typos, r=alexcrichton
I found these automatically, but fixed them manually to ensure the semantics are correct. I know things like these are hardly important, since they only marginally improve clarity. But at least for me typos and simple grammatical errors trigger an---unjustified---sense of unprofessionalism, despite the fact that I make them all the time and I understand that they're the sort of thing that is bound to slip through review.
Anyway, to find most of these I used:
* `ag '.*//.*(\b[A-Za-z]{2,}\b) \1\b'` for repeated words
* `ag '\b(the|this|those|these|a|it) (a|the|this|those|these|it)\b'` to find constructs like 'the this' etc. many false positives, but not too hard to scroll through them to actually find the mistakes.
* `cat ../../typos.txt | paste -d'|' - - - - - - - - - - - - - - - - - - - - - - | tr '\n' '\0' | xargs -0 -P4 -n1 ag`. Hacky way to find misspellings, but it works ok. I got `typos.txt` from [Wikipedia](https://en.wikipedia.org/wiki/Wikipedia:Lists_of_common_misspellings/For_machines)
* `ag '.*//.* a ([ae][a-z]|(o[^n])|(i[a-rt-z]))'` to find places where 'a' was followed by a vowel (requiring 'an' instead).
I also used a handful more one off regexes that are too boring to reproduce here.
Diffstat (limited to 'src/libsyntax')
| -rw-r--r-- | src/libsyntax/ext/base.rs | 2 | ||||
| -rw-r--r-- | src/libsyntax/ext/tt/macro_parser.rs | 2 | ||||
| -rw-r--r-- | src/libsyntax/ext/tt/macro_rules.rs | 2 | ||||
| -rw-r--r-- | src/libsyntax/feature_gate.rs | 3 |
4 files changed, 4 insertions, 5 deletions
diff --git a/src/libsyntax/ext/base.rs b/src/libsyntax/ext/base.rs index aaaca8bd4d8..7459f8b8f24 100644 --- a/src/libsyntax/ext/base.rs +++ b/src/libsyntax/ext/base.rs @@ -600,7 +600,7 @@ impl<'a> ExtCtxt<'a> { self.expander().fold_expr(e) } - /// Returns a `Folder` for deeply expanding all macros in a AST node. + /// Returns a `Folder` for deeply expanding all macros in an AST node. pub fn expander<'b>(&'b mut self) -> expand::MacroExpander<'b, 'a> { expand::MacroExpander::new(self) } diff --git a/src/libsyntax/ext/tt/macro_parser.rs b/src/libsyntax/ext/tt/macro_parser.rs index 01fd4608ecb..8dec9ae1e98 100644 --- a/src/libsyntax/ext/tt/macro_parser.rs +++ b/src/libsyntax/ext/tt/macro_parser.rs @@ -32,7 +32,7 @@ //! As it processes them, it fills up `eof_eis` with items that would be valid if //! the macro invocation is now over, `bb_eis` with items that are waiting on //! a Rust nonterminal like `$e:expr`, and `next_eis` with items that are waiting -//! on the a particular token. Most of the logic concerns moving the · through the +//! on a particular token. Most of the logic concerns moving the · through the //! repetitions indicated by Kleene stars. It only advances or calls out to the //! real Rust parser when no `cur_eis` items remain //! diff --git a/src/libsyntax/ext/tt/macro_rules.rs b/src/libsyntax/ext/tt/macro_rules.rs index 0a95f24a721..cce4450b299 100644 --- a/src/libsyntax/ext/tt/macro_rules.rs +++ b/src/libsyntax/ext/tt/macro_rules.rs @@ -497,7 +497,7 @@ fn is_in_follow(_: &ExtCtxt, tok: &Token, frag: &str) -> Result<bool, String> { Ok(true) }, "block" => { - // anything can follow block, the braces provide a easy boundary to + // anything can follow block, the braces provide an easy boundary to // maintain Ok(true) }, diff --git a/src/libsyntax/feature_gate.rs b/src/libsyntax/feature_gate.rs index 18c6d74d62e..39b1b746de8 100644 --- a/src/libsyntax/feature_gate.rs +++ b/src/libsyntax/feature_gate.rs @@ -1107,8 +1107,7 @@ pub enum UnstableFeatures { /// Errors are bypassed for bootstrapping. This is required any time /// during the build that feature-related lints are set to warn or above /// because the build turns on warnings-as-errors and uses lots of unstable - /// features. As a result, this this is always required for building Rust - /// itself. + /// features. As a result, this is always required for building Rust itself. Cheat } |
