Feature flag for nom dependency
diff --git a/src/common.rs b/src/common.rs
index 3cd8587..b24e9ee 100644
--- a/src/common.rs
+++ b/src/common.rs
@@ -6,15 +6,18 @@
Inherited,
}
+#[cfg(feature = "parsing")]
fn ident_ch(ch: char) -> bool {
ch.is_alphanumeric() || ch == '_'
}
+#[cfg(feature = "parsing")]
named!(pub word<&str, Ident>, preceded!(
opt!(call!(::nom::multispace)),
map!(take_while1_s!(ident_ch), String::from)
));
+#[cfg(feature = "parsing")]
named!(pub visibility<&str, Visibility>, preceded!(
opt!(call!(::nom::multispace)),
alt!(