diff options
| author | Hannes Schulze <haschu0103@outlook.de> | 2024-11-03 21:07:34 +0100 |
|---|---|---|
| committer | Hannes Schulze <haschu0103@outlook.de> | 2024-11-03 21:12:10 +0100 |
| commit | e36217208802c001f1fbc758e5f103cbc4f339a2 (patch) | |
| tree | 6b11d491a9bf110d1f89ce9ab8809adf72ca2a4b /src/services/quick-answers/math.h | |
| parent | 497f0388aee4b7ae0df92bb2b3617c524e5a5496 (diff) | |
add unit tests for math
Diffstat (limited to 'src/services/quick-answers/math.h')
| -rw-r--r-- | src/services/quick-answers/math.h | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/src/services/quick-answers/math.h b/src/services/quick-answers/math.h index 6bc07fe..c66a2bf 100644 --- a/src/services/quick-answers/math.h +++ b/src/services/quick-answers/math.h @@ -123,22 +123,23 @@ void foobar_math_value_copy ( FoobarMathValue FoobarMathValue* out_value ); void foobar_math_value_free ( FoobarMathValue value ); void foobar_math_value_negate ( FoobarMathValue* value ); -gboolean foobar_math_value_add ( FoobarMathValue lhs, - FoobarMathValue rhs, +gboolean foobar_math_value_add ( FoobarMathValue* lhs, + FoobarMathValue* rhs, FoobarMathValue* out_value ); -gboolean foobar_math_value_sub ( FoobarMathValue lhs, - FoobarMathValue rhs, +gboolean foobar_math_value_sub ( FoobarMathValue* lhs, + FoobarMathValue* rhs, FoobarMathValue* out_value ); -gboolean foobar_math_value_mul ( FoobarMathValue lhs, - FoobarMathValue rhs, +gboolean foobar_math_value_mul ( FoobarMathValue* lhs, + FoobarMathValue* rhs, FoobarMathValue* out_value ); -gboolean foobar_math_value_div ( FoobarMathValue lhs, - FoobarMathValue rhs, +gboolean foobar_math_value_div ( FoobarMathValue* lhs, + FoobarMathValue* rhs, FoobarMathValue* out_value ); -gboolean foobar_math_value_pow ( FoobarMathValue lhs, - FoobarMathValue rhs, +gboolean foobar_math_value_pow ( FoobarMathValue* lhs, + FoobarMathValue* rhs, FoobarMathValue* out_value ); -gboolean foobar_math_value_is_simple_int ( FoobarMathValue value ); +gboolean foobar_math_value_unify_integers ( FoobarMathValue* a, + FoobarMathValue* b ); gchar* foobar_math_value_to_string ( FoobarMathValue value ); long double foobar_math_value_to_float ( FoobarMathValue value ); gboolean foobar_math_evaluate ( FoobarMathExpression const* expr, |
