about summary refs log tree commit diff
path: root/src/libsyntax/parse/mod.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2019-10-17 18:53:10 +0000
committerbors <bors@rust-lang.org>2019-10-17 18:53:10 +0000
commitfa0f7d0080d8e7e9eb20aa9cbf8013f96c81287f (patch)
tree50e8894f986895d96ddf501e5c894ee920d1bcc7 /src/libsyntax/parse/mod.rs
parentb04338087eed5f26c72bdb0e426dc38e215e2dbb (diff)
parent060aedd385d363924bd7f645073eb74bb2aa8a5e (diff)
downloadrust-fa0f7d0080d8e7e9eb20aa9cbf8013f96c81287f.tar.gz
rust-fa0f7d0080d8e7e9eb20aa9cbf8013f96c81287f.zip
Auto merge of #65495 - Centril:rollup-tguwjt5, r=Centril
Rollup of 8 pull requests

Successful merges:

 - #65237 (Move debug_map assertions after check for err)
 - #65316 (make File::try_clone produce non-inheritable handles on Windows)
 - #65319 (InterpCx: make memory field public)
 - #65461 (Don't recommend ONCE_INIT in std::sync::Once)
 - #65465 (Move syntax::ext to a syntax_expand and refactor some attribute logic)
 - #65475 (add example for type_name)
 - #65478 (fmt::Write is about string slices, not byte slices)
 - #65486 (doc: fix typo in OsStrExt and OsStringExt)

Failed merges:

r? @ghost
Diffstat (limited to 'src/libsyntax/parse/mod.rs')
-rw-r--r--src/libsyntax/parse/mod.rs28
1 files changed, 1 insertions, 27 deletions
diff --git a/src/libsyntax/parse/mod.rs b/src/libsyntax/parse/mod.rs
index cb90caab77a..e6b794a6a99 100644
--- a/src/libsyntax/parse/mod.rs
+++ b/src/libsyntax/parse/mod.rs
@@ -2,7 +2,7 @@
 
 use crate::ast;
 use crate::parse::parser::{Parser, emit_unclosed_delims};
-use crate::parse::token::{Nonterminal, TokenKind};
+use crate::parse::token::Nonterminal;
 use crate::tokenstream::{self, TokenStream, TokenTree};
 use crate::print::pprust;
 use crate::sess::ParseSess;
@@ -24,12 +24,10 @@ mod tests;
 
 #[macro_use]
 pub mod parser;
-pub mod attr;
 pub mod lexer;
 pub mod token;
 
 crate mod classify;
-crate mod diagnostics;
 crate mod literal;
 crate mod unescape_error_reporting;
 
@@ -273,30 +271,6 @@ pub fn stream_to_parser_with_base_dir<'a>(
     Parser::new(sess, stream, Some(base_dir), true, false, None)
 }
 
-/// A sequence separator.
-pub struct SeqSep {
-    /// The separator token.
-    pub sep: Option<TokenKind>,
-    /// `true` if a trailing separator is allowed.
-    pub trailing_sep_allowed: bool,
-}
-
-impl SeqSep {
-    pub fn trailing_allowed(t: TokenKind) -> SeqSep {
-        SeqSep {
-            sep: Some(t),
-            trailing_sep_allowed: true,
-        }
-    }
-
-    pub fn none() -> SeqSep {
-        SeqSep {
-            sep: None,
-            trailing_sep_allowed: false,
-        }
-    }
-}
-
 // NOTE(Centril): The following probably shouldn't be here but it acknowledges the
 // fact that architecturally, we are using parsing (read on below to understand why).