includes/std: Added std::math::exp(), fixed std::math::ln comment (#106)

Removed extraneous argument base to ln function and added the necessary definition in include file to access previously builtin function exp.
This commit is contained in:
paxcut
2023-04-17 13:19:47 -07:00
committed by GitHub
parent b9af43e08b
commit 8f1a6bdd75

View File

@@ -178,7 +178,6 @@ namespace std::math {
/**
Calculates the natural logarithm of `value`.
@param value Value
@param base Base
@return Logarithm of `value` with base `e`
*/
fn ln(auto value) { return builtin::std::math::ln(value); };
@@ -198,6 +197,13 @@ namespace std::math {
*/
fn pow(auto base, auto exp) { return builtin::std::math::pow(base, exp); };
/**
Calculates the value of the natural number `e` raised to the power of `value`.
@param value Exponent
@return `e` raised to the power of `value`
*/
fn exp(auto value) { return builtin::std::math::exp(value); };
/**
Calculates the square root of `value`.
@param value Value