feat: Num.toStr

* add type for Num.toStr
  * create new lowlevel
  * delete types and Symbol for fromInt and fromFloat
  * leave LowLevel::{StrFromFloat,StrFromInt}
  * match on LowLevel::NumToStr and figure out the layout to decide
    which build function to delegate to
This commit is contained in:
rvcas 2021-11-30 14:52:06 -05:00
parent d67cc883ca
commit f995a07029
8 changed files with 65 additions and 75 deletions

View file

@ -406,7 +406,7 @@ pub fn str_from_utf8<'a, 'ctx, 'env>(
decode_from_utf8_result(env, result_ptr).into()
}
/// Str.fromInt : Int -> Str
/// Str.fromFloat : Int -> Str
pub fn str_from_float<'a, 'ctx, 'env>(
env: &Env<'a, 'ctx, 'env>,
scope: &Scope<'a, 'ctx>,