@@ -467,6 +467,27 @@ typedef struct LDKStr {
467
467
bool chars_is_owned;
468
468
} LDKStr;
469
469
470
+ /**
471
+ * Represents a scalar value between zero and the secp256k1 curve order, in big endian.
472
+ */
473
+ typedef struct LDKBigEndianScalar {
474
+ /**
475
+ * The bytes of the scalar value.
476
+ */
477
+ uint8_t big_endian_bytes[32];
478
+ } LDKBigEndianScalar;
479
+
480
+ /**
481
+ * Arbitrary 32 bytes, which could represent one of a few different things. You probably want to
482
+ * look up the corresponding function in rust-lightning's docs.
483
+ */
484
+ typedef struct LDKThirtyTwoBytes {
485
+ /**
486
+ * The thirty-two bytes
487
+ */
488
+ uint8_t data[32];
489
+ } LDKThirtyTwoBytes;
490
+
470
491
/**
471
492
* Represents an error returned from the bech32 library during validation of some bech32 data
472
493
*/
@@ -2437,17 +2458,6 @@ typedef struct LDKCResult_RouteLightningErrorZ {
2437
2458
bool result_ok;
2438
2459
} LDKCResult_RouteLightningErrorZ;
2439
2460
2440
- /**
2441
- * Arbitrary 32 bytes, which could represent one of a few different things. You probably want to
2442
- * look up the corresponding function in rust-lightning's docs.
2443
- */
2444
- typedef struct LDKThirtyTwoBytes {
2445
- /**
2446
- * The thirty-two bytes
2447
- */
2448
- uint8_t data[32];
2449
- } LDKThirtyTwoBytes;
2450
-
2451
2461
/**
2452
2462
* Some information provided on receipt of payment depends on whether the payment received is a
2453
2463
* spontaneous payment or a \"conventional\" lightning payment that's paying an invoice.
@@ -6407,16 +6417,6 @@ typedef struct LDKCResult_SecretKeyNoneZ {
6407
6417
bool result_ok;
6408
6418
} LDKCResult_SecretKeyNoneZ;
6409
6419
6410
- /**
6411
- * Represents a scalar value between zero and the secp256k1 curve order, in big endian.
6412
- */
6413
- typedef struct LDKBigEndianScalar {
6414
- /**
6415
- * The bytes of the scalar value.
6416
- */
6417
- uint8_t big_endian_bytes[32];
6418
- } LDKBigEndianScalar;
6419
-
6420
6420
/**
6421
6421
* An enum which can either contain a crate::c_types::BigEndianScalar or not
6422
6422
*/
@@ -13896,6 +13896,11 @@ struct LDKStr _ldk_get_compiled_version(void);
13896
13896
13897
13897
struct LDKStr _ldk_c_bindings_get_compiled_version(void);
13898
13898
13899
+ /**
13900
+ * Convenience function for constructing a new BigEndianScalar
13901
+ */
13902
+ struct LDKBigEndianScalar BigEndianScalar_new(struct LDKThirtyTwoBytes big_endian_bytes);
13903
+
13899
13904
/**
13900
13905
* Creates a new Bech32Error which has the same data as `orig`
13901
13906
*/
0 commit comments