Fix no_std build.

This commit is contained in:
Stephen Chung
2021-03-01 09:30:23 +08:00
parent 8eee21ff38
commit 733f4af8b3
3 changed files with 7 additions and 2 deletions

View File

@@ -348,7 +348,11 @@ impl EvalAltResult {
pub(crate) fn dump_fields(&self, map: &mut crate::Map) {
map.insert(
"error".into(),
format!("{:?}", self).split('(').next().unwrap().into(),
crate::stdlib::format!("{:?}", self)
.split('(')
.next()
.unwrap()
.into(),
);
match self {