diff options
| author | bors <bors@rust-lang.org> | 2015-10-09 08:53:45 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2015-10-09 08:53:45 +0000 |
| commit | c14609035d1780d4a8a3ca7b4fdf93046299ab4a (patch) | |
| tree | e2cd7e864e6d87be5ef3f9c044d0d2a510c6c96e /src/libsyntax/codemap.rs | |
| parent | 7cea9a714130b7b85caf91c2a1d126539f41c383 (diff) | |
| parent | a62a529eea3e00b3ce9e659daa4235add2cb8551 (diff) | |
| download | rust-c14609035d1780d4a8a3ca7b4fdf93046299ab4a.tar.gz rust-c14609035d1780d4a8a3ca7b4fdf93046299ab4a.zip | |
Auto merge of #28857 - nrc:lowering, r=nikomatsakis
r? @nikomatsakis
Diffstat (limited to 'src/libsyntax/codemap.rs')
| -rw-r--r-- | src/libsyntax/codemap.rs | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/src/libsyntax/codemap.rs b/src/libsyntax/codemap.rs index aa4dd1d53c5..a73fd4534c9 100644 --- a/src/libsyntax/codemap.rs +++ b/src/libsyntax/codemap.rs @@ -29,7 +29,6 @@ use std::io::{self, Read}; use serialize::{Encodable, Decodable, Encoder, Decoder}; -use parse::token::intern; use ast::Name; // _____________________________________________________________________________ @@ -269,28 +268,8 @@ pub enum ExpnFormat { MacroAttribute(Name), /// e.g. `format!()` MacroBang(Name), - /// Syntax sugar expansion performed by the compiler (libsyntax::expand). - CompilerExpansion(CompilerExpansionFormat), } -#[derive(Clone, Copy, Hash, Debug, PartialEq, Eq)] -pub enum CompilerExpansionFormat { - IfLet, - PlacementIn, - WhileLet, - ForLoop, -} - -impl CompilerExpansionFormat { - pub fn name(self) -> &'static str { - match self { - CompilerExpansionFormat::IfLet => "if let expansion", - CompilerExpansionFormat::PlacementIn => "placement-in expansion", - CompilerExpansionFormat::WhileLet => "while let expansion", - CompilerExpansionFormat::ForLoop => "for loop expansion", - } - } -} #[derive(Clone, Hash, Debug)] pub struct NameAndSpan { /// The format with which the macro was invoked. @@ -310,7 +289,6 @@ impl NameAndSpan { match self.format { ExpnFormat::MacroAttribute(s) => s, ExpnFormat::MacroBang(s) => s, - ExpnFormat::CompilerExpansion(ce) => intern(ce.name()), } } } |
