Replace separate strlen(buffer) calls with the length returned directly by sprintf in both num_toString and range_toString native functions. This avoids an unnecessary pass over the formatted string buffer, improving performance for these hot-path number and range conversions.