fix build on wasm
This commit is contained in:
parent
004ca3a7ed
commit
66f24c474d
@ -88,9 +88,6 @@ use codemap::{Span, Spanned};
|
|||||||
|
|
||||||
use peekmore::{PeekMore, PeekMoreIterator};
|
use peekmore::{PeekMore, PeekMoreIterator};
|
||||||
|
|
||||||
#[cfg(feature = "wasm")]
|
|
||||||
use wasm_bindgen::prelude::*;
|
|
||||||
|
|
||||||
use crate::atrule::{AtRule, AtRuleKind, Function, Mixin};
|
use crate::atrule::{AtRule, AtRuleKind, Function, Mixin};
|
||||||
pub use crate::error::{SassError, SassResult};
|
pub use crate::error::{SassError, SassResult};
|
||||||
use crate::scope::{insert_global_var, Scope};
|
use crate::scope::{insert_global_var, Scope};
|
||||||
|
@ -21,6 +21,10 @@ arg_enum! {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[cfg(feature = "wasm")]
|
||||||
|
fn main() {}
|
||||||
|
|
||||||
|
#[cfg(not(feature = "wasm"))]
|
||||||
#[cfg_attr(feature = "profiling", inline(never))]
|
#[cfg_attr(feature = "profiling", inline(never))]
|
||||||
fn main() -> std::io::Result<()> {
|
fn main() -> std::io::Result<()> {
|
||||||
let matches = App::new("grass")
|
let matches = App::new("grass")
|
||||||
|
@ -41,7 +41,7 @@ impl StyleSheet {
|
|||||||
StyleSheetParser {
|
StyleSheetParser {
|
||||||
lexer: Lexer::new(&file).peekmore(),
|
lexer: Lexer::new(&file).peekmore(),
|
||||||
nesting: 0,
|
nesting: 0,
|
||||||
map: &map,
|
map: &mut map,
|
||||||
path: Path::new(""),
|
path: Path::new(""),
|
||||||
}
|
}
|
||||||
.parse_toplevel()
|
.parse_toplevel()
|
||||||
@ -49,7 +49,7 @@ impl StyleSheet {
|
|||||||
.0,
|
.0,
|
||||||
))
|
))
|
||||||
.map_err(|e| raw_to_parse_error(&map, e).to_string())?
|
.map_err(|e| raw_to_parse_error(&map, e).to_string())?
|
||||||
.pretty_print()
|
.pretty_print(&map)
|
||||||
.map_err(|e| raw_to_parse_error(&map, e).to_string())?)
|
.map_err(|e| raw_to_parse_error(&map, e).to_string())?)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user