From 83cdae63e8c3428c3dd5c127f349cf8d4416ff5b Mon Sep 17 00:00:00 2001 From: reedlepee Date: Tue, 29 Oct 2013 05:01:56 +0530 Subject: [PATCH] Replaced empty destructors with NonCopyable #7427 closes #7427 --- src/libsyntax/parse/parser.rs | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs index 5a5e310e56f..59e92501fc2 100644 --- a/src/libsyntax/parse/parser.rs +++ b/src/libsyntax/parse/parser.rs @@ -340,13 +340,10 @@ pub struct Parser { mod_path_stack: @mut ~[@str], /// Stack of spans of open delimiters. Used for error message. open_braces: @mut ~[Span] + /// removed empty drop function and added a priv new_field of type std::util::NonCopyable + priv new_field: util::NonCopyable } -#[unsafe_destructor] -impl Drop for Parser { - /* do not copy the parser; its state is tied to outside state */ - fn drop(&mut self) {} -} fn is_plain_ident_or_underscore(t: &token::Token) -> bool { is_plain_ident(t) || *t == token::UNDERSCORE