From 4c379ff4c74216fba40c23586c6b337daf3ba2d7 Mon Sep 17 00:00:00 2001 From: Greg Morenz Date: Mon, 15 Feb 2016 16:44:51 -0500 Subject: [PATCH] Update ast::BiEq to BinOpKind::Eq --- num-macros/src/lib.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/num-macros/src/lib.rs b/num-macros/src/lib.rs index 0b4ca60..26e2f8e 100644 --- a/num-macros/src/lib.rs +++ b/num-macros/src/lib.rs @@ -14,7 +14,7 @@ extern crate syntax; extern crate syntax_ext; extern crate rustc_plugin; -use syntax::ast::{MetaItem, Expr}; +use syntax::ast::{MetaItem, Expr, BinOpKind}; use syntax::ast; use syntax::codemap::Span; use syntax::ext::base::{ExtCtxt, Annotatable}; @@ -142,7 +142,7 @@ fn cs_from(name: &str, cx: &mut ExtCtxt, trait_span: Span, substr: &Substructure let variant = cx.expr_path(path); let ty = cx.ty_ident(span, cx.ident_of(name)); let cast = cx.expr_cast(span, variant.clone(), ty); - let guard = cx.expr_binary(span, ast::BiEq, n.clone(), cast); + let guard = cx.expr_binary(span, BinOpKind::Eq, n.clone(), cast); // expr for `Some($variant)` let body = cx.expr_some(span, variant);