Replaced empty destructors with NonCopyable #7427

closes #7427
This commit is contained in:
reedlepee 2013-10-29 05:01:56 +05:30
parent fc766efd16
commit 83cdae63e8

View file

@ -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