Avoid unused warnings when building on Fuchsia
//! Structured representation of a plugin's features and capabilities.
-use std::env;
use std::path::PathBuf;
use syntax::SyntaxDefinition;
// optional environment variable for debug plugin executables
+#[cfg(not(target_os = "fuchsia"))]
static PLUGIN_DIR: &'static str = "XI_PLUGIN_DIR";
// example plugins. Eventually these should be loaded from disk.
#[cfg(not(target_os = "fuchsia"))]
pub fn debug_plugins() -> Vec<PluginDescription> {
+ use std::env;
use self::PluginActivation::*;
use self::PluginScope::*;
let plugin_dir = match env::var(PLUGIN_DIR).map(PathBuf::from) {
@@ -106,6 +107,7 @@ pub enum PluginScope {
SingleInvocation,
}
+#[cfg(not(target_os = "fuchsia"))]
impl PluginDescription {
fn new<S, P>(name: S, version: S, scope: PluginScope, exec_path: P,
activations: Vec<PluginActivation>) -> Self
