merge and respond to feedback

This commit is contained in:
Mackenzie Clark
2019-03-28 11:41:45 -07:00
20 changed files with 234 additions and 41 deletions

View File

@ -7,6 +7,8 @@ use crate::{
};
use std::{ffi::c_void, mem, ptr};
use hashbrown::HashMap;
/// The context of the currently running WebAssembly instance.
///
///
@ -156,6 +158,11 @@ impl Ctx {
},
}
}
/// Gives access to the emscripten symbol map, used for debugging
pub unsafe fn borrow_symbol_map(&self) -> &Option<HashMap<u32, String>> {
&(*self.module).info.em_symbol_map
}
}
#[doc(hidden)]
@ -609,6 +616,8 @@ mod vm_ctx_tests {
namespace_table: StringTable::new(),
name_table: StringTable::new(),
em_symbol_map: None,
custom_sections: HashMap::new(),
},
}