about summary refs log tree commit diff
path: root/src/libsyntax
diff options
context:
space:
mode:
authorJulien Cretin <cretin@google.com>2019-07-24 23:21:25 +0200
committerJulien Cretin <cretin@google.com>2019-07-27 11:50:09 +0200
commitf176bcf7420dbc4b8cc297f1fdbff32813c558a7 (patch)
tree7077c01b689ee16c6111d6ce4af0a17db3fb132f /src/libsyntax
parent09e39897587dca70f0b15093d425a682c392349c (diff)
downloadrust-f176bcf7420dbc4b8cc297f1fdbff32813c558a7.tar.gz
rust-f176bcf7420dbc4b8cc297f1fdbff32813c558a7.zip
Fix typo in Delimited::open_tt
Diffstat (limited to 'src/libsyntax')
-rw-r--r--src/libsyntax/ext/tt/macro_rules.rs2
-rw-r--r--src/libsyntax/ext/tt/quoted.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/libsyntax/ext/tt/macro_rules.rs b/src/libsyntax/ext/tt/macro_rules.rs
index 2a2df76d30c..280bff8c1a1 100644
--- a/src/libsyntax/ext/tt/macro_rules.rs
+++ b/src/libsyntax/ext/tt/macro_rules.rs
@@ -748,7 +748,7 @@ impl TokenSet {
 }
 
 // Checks that `matcher` is internally consistent and that it
-// can legally by followed by a token N, for all N in `follow`.
+// can legally be followed by a token `N`, for all `N` in `follow`.
 // (If `follow` is empty, then it imposes no constraint on
 // the `matcher`.)
 //
diff --git a/src/libsyntax/ext/tt/quoted.rs b/src/libsyntax/ext/tt/quoted.rs
index f67e4d368cc..cad94a0e4c1 100644
--- a/src/libsyntax/ext/tt/quoted.rs
+++ b/src/libsyntax/ext/tt/quoted.rs
@@ -27,7 +27,7 @@ impl Delimited {
         let open_span = if span.is_dummy() {
             span
         } else {
-            span.with_lo(span.lo() + BytePos(self.delim.len() as u32))
+            span.with_hi(span.lo() + BytePos(self.delim.len() as u32))
         };
         TokenTree::token(token::OpenDelim(self.delim), open_span)
     }