Remove need for smartstring/std.

This commit is contained in:
Stephen Chung 2022-09-22 23:11:38 +08:00
parent ea5ff2ac5f
commit f2b1184805
2 changed files with 2 additions and 2 deletions

View File

@ -8,7 +8,7 @@ Bug fixes
---------
* Compiling on 32-bit architectures no longer cause a compilation error.
* Fix type-size test fo 32-bit architectures without the `decimal` feature.
* Fix type-size test for 32-bit architectures without the `decimal` feature.
Custom syntax with state
------------------------

View File

@ -108,7 +108,7 @@ impl Engine {
pub fn compile_file_with_scope(&self, scope: &Scope, path: PathBuf) -> RhaiResultOf<AST> {
Self::read_file(&path).and_then(|contents| {
let mut ast = self.compile_with_scope(scope, &contents)?;
ast.set_source(path.to_string_lossy());
ast.set_source(path.to_string_lossy().as_ref());
Ok(ast)
})
}