about summary refs log tree commit diff
path: root/src/libsyntax_ext
diff options
context:
space:
mode:
authorVadim Petrochenkov <vadim.petrochenkov@gmail.com>2018-06-27 01:59:07 +0300
committerVadim Petrochenkov <vadim.petrochenkov@gmail.com>2018-07-14 14:57:14 +0300
commite3acb341b2ff743e186c032326d24bfa8827bedc (patch)
treec7080793f49bb9c75752cee93830a5b49bf9d0e8 /src/libsyntax_ext
parent5987fe8f75c443d4f73603fa5a3af8ab41ee1b01 (diff)
downloadrust-e3acb341b2ff743e186c032326d24bfa8827bedc.tar.gz
rust-e3acb341b2ff743e186c032326d24bfa8827bedc.zip
Remove some tests using AST comparisons, fix other tests
Diffstat (limited to 'src/libsyntax_ext')
-rw-r--r--src/libsyntax_ext/format_foreign.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libsyntax_ext/format_foreign.rs b/src/libsyntax_ext/format_foreign.rs
index 1cf21b5c3ae..ff9663cdd3c 100644
--- a/src/libsyntax_ext/format_foreign.rs
+++ b/src/libsyntax_ext/format_foreign.rs
@@ -12,7 +12,7 @@ pub mod printf {
     use super::strcursor::StrCursor as Cur;
 
     /// Represents a single `printf`-style substitution.
-    #[derive(Clone, Debug)]
+    #[derive(Clone, PartialEq, Debug)]
     pub enum Substitution<'a> {
         /// A formatted output substitution.
         Format(Format<'a>),
@@ -40,7 +40,7 @@ pub mod printf {
         }
     }
 
-    #[derive(Clone, Debug)]
+    #[derive(Clone, PartialEq, Debug)]
     /// A single `printf`-style formatting directive.
     pub struct Format<'a> {
         /// The entire original formatting directive.
@@ -213,7 +213,7 @@ pub mod printf {
     }
 
     /// A general number used in a `printf` formatting directive.
-    #[derive(Copy, Clone, Debug)]
+    #[derive(Copy, Clone, PartialEq, Debug)]
     pub enum Num {
         // The range of these values is technically bounded by `NL_ARGMAX`... but, at least for GNU
         // libc, it apparently has no real fixed limit.  A `u16` is used here on the basis that it
@@ -739,7 +739,7 @@ pub mod printf {
 pub mod shell {
     use super::strcursor::StrCursor as Cur;
 
-    #[derive(Clone, Debug)]
+    #[derive(Clone, PartialEq, Debug)]
     pub enum Substitution<'a> {
         Ordinal(u8),
         Name(&'a str),