浏览代码

Merge #31

31: Fix attrs r=IsaacWoods a=Restioson

Don't extern crate std on non-test profiles (so it works in no_std)

Co-authored-by: restioson <restiosondev@gmail.com>
bors[bot] 6 年之前
父节点
当前提交
465ecf749c
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      src/lib.rs

+ 2 - 1
src/lib.rs

@@ -4,7 +4,8 @@
 #![feature(exclusive_range_pattern, range_contains)]
 #![feature(exhaustive_integer_patterns)]
 
-#[macro_use]
+#[cfg_attr(test, macro_use)]
+#[cfg(test)]
 extern crate std;
 
 #[macro_use]