summaryrefslogtreecommitdiffstats
path: root/toolkit/components/uniffi-fixtures/arithmetic/src/arithmetic.udl
blob: 117df4834aa410161c7acaf00e9fa6d32fc5b333 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
[Error]
enum ArithmeticError {
  "IntegerOverflow",
};

namespace arithmetic {
  [Throws=ArithmeticError]
  u64 add(u64 a, u64 b);

  [Throws=ArithmeticError]
  u64 sub(u64 a, u64 b);

  u64 div(u64 dividend, u64 divisor);

  boolean equal(u64 a, u64 b);
};