add many emscripten functions for PHP

This commit is contained in:
Mark McCaskey
2019-03-20 15:13:00 -07:00
parent 40be4da925
commit 42b122d639
4 changed files with 199 additions and 1 deletions

View File

@ -37,3 +37,13 @@ pub fn f64_rem(_ctx: &mut Ctx, x: f64, y: f64) -> f64 {
pub fn pow(_ctx: &mut Ctx, x: f64, y: f64) -> f64 {
x.powf(y)
}
// emscripten: global.Math exp
pub fn exp(_ctx: &mut Ctx, value: f64) -> f64 {
value.exp()
}
// emscripten: global.Math log
pub fn log(_ctx: &mut Ctx, value: f64) -> f64 {
value.ln()
}