summaryrefslogtreecommitdiff
path: root/src/include
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2020-08-29 11:55:40 +0200
committerChristian Grothoff <christian@grothoff.org>2020-08-29 11:55:40 +0200
commit2aca3b5effc94c6749bb872b939f2d29feacda7a (patch)
tree6d5d0ec898f34d91f35f2c24eeacf90e252f4e69 /src/include
parent3bba677f64254458ad6beed1b018abe2d3e0a3c3 (diff)
downloadexchange-2aca3b5effc94c6749bb872b939f2d29feacda7a.tar.gz
exchange-2aca3b5effc94c6749bb872b939f2d29feacda7a.tar.bz2
exchange-2aca3b5effc94c6749bb872b939f2d29feacda7a.zip
use enum instead of int
Diffstat (limited to 'src/include')
-rw-r--r--src/include/taler_amount_lib.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/include/taler_amount_lib.h b/src/include/taler_amount_lib.h
index 4f6d14004..7a0b299c4 100644
--- a/src/include/taler_amount_lib.h
+++ b/src/include/taler_amount_lib.h
@@ -123,7 +123,7 @@ struct TALER_Amount
* @return #GNUNET_OK if the string is a valid monetary amount specification,
* #GNUNET_SYSERR if it is invalid.
*/
-int
+enum GNUNET_GenericReturnValue
TALER_string_to_amount (const char *str,
struct TALER_Amount *amount);
@@ -137,7 +137,7 @@ TALER_string_to_amount (const char *str,
* @return #GNUNET_OK if the string is a valid amount specification,
* #GNUNET_SYSERR if it is invalid.
*/
-int
+enum GNUNET_GenericReturnValue
TALER_string_to_amount_nbo (const char *str,
struct TALER_AmountNBO *amount_nbo);
@@ -150,7 +150,7 @@ TALER_string_to_amount_nbo (const char *str,
* @return #GNUNET_OK if @a cur is a valid currency specification,
* #GNUNET_SYSERR if it is invalid.
*/
-int
+enum GNUNET_GenericReturnValue
TALER_amount_get_zero (const char *cur,
struct TALER_Amount *amount);
@@ -161,7 +161,7 @@ TALER_amount_get_zero (const char *cur,
* @param amount amount to check
* @return #GNUNET_OK if @a amount is valid
*/
-int
+enum GNUNET_GenericReturnValue
TALER_amount_is_valid (const struct TALER_Amount *amount);
@@ -232,7 +232,7 @@ TALER_amount_cmp_nbo (const struct TALER_AmountNBO *a1,
* #GNUNET_NO if the currencies are different
* #GNUNET_SYSERR if either amount is invalid
*/
-int
+enum GNUNET_GenericReturnValue
TALER_amount_cmp_currency (const struct TALER_Amount *a1,
const struct TALER_Amount *a2);
@@ -246,7 +246,7 @@ TALER_amount_cmp_currency (const struct TALER_Amount *a1,
* #GNUNET_NO if the currencies are different
* #GNUNET_SYSERR if either amount is invalid
*/
-int
+enum GNUNET_GenericReturnValue
TALER_amount_cmp_currency_nbo (const struct TALER_AmountNBO *a1,
const struct TALER_AmountNBO *a2);
@@ -379,7 +379,7 @@ TALER_amount2s (const struct TALER_Amount *amount);
* @return #GNUNET_OK on success, #GNUNET_NO if rounding was unnecessary,
* #GNUNET_SYSERR if the amount or currency or @a round_unit was invalid
*/
-int
+enum GNUNET_GenericReturnValue
TALER_amount_round_down (struct TALER_Amount *amount,
const struct TALER_Amount *round_unit);