Skip to content

Commit a38d879

Browse files
Merge #1628: Name public API structs
694342f Name public API structs (Ava Chow) Pull request description: Closes #1627 ACKs for top commit: real-or-random: utACK 694342f jonasnick: ACK 694342f Tree-SHA512: 4e03d97e7c072fc7ddefe3f679878aa8a806f3f557a736c9a1b9137972798c953cb21b91491d65f7ba5d75d7119e3224ce60309a0ff93fcf9a64b57b4a426655
2 parents 7d48f5e + 694342f commit a38d879

File tree

5 files changed

+12
-12
lines changed

5 files changed

+12
-12
lines changed

include/secp256k1.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ typedef struct secp256k1_context_struct secp256k1_context;
5858
* use secp256k1_ec_pubkey_serialize and secp256k1_ec_pubkey_parse. To
5959
* compare keys, use secp256k1_ec_pubkey_cmp.
6060
*/
61-
typedef struct {
61+
typedef struct secp256k1_pubkey {
6262
unsigned char data[64];
6363
} secp256k1_pubkey;
6464

@@ -71,7 +71,7 @@ typedef struct {
7171
* comparison, use the secp256k1_ecdsa_signature_serialize_* and
7272
* secp256k1_ecdsa_signature_parse_* functions.
7373
*/
74-
typedef struct {
74+
typedef struct secp256k1_ecdsa_signature {
7575
unsigned char data[64];
7676
} secp256k1_ecdsa_signature;
7777

include/secp256k1_extrakeys.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ extern "C" {
1919
* use secp256k1_xonly_pubkey_serialize and secp256k1_xonly_pubkey_parse. To
2020
* compare keys, use secp256k1_xonly_pubkey_cmp.
2121
*/
22-
typedef struct {
22+
typedef struct secp256k1_xonly_pubkey {
2323
unsigned char data[64];
2424
} secp256k1_xonly_pubkey;
2525

@@ -30,7 +30,7 @@ typedef struct {
3030
* guaranteed to be portable between different platforms or versions. It is
3131
* however guaranteed to be 96 bytes in size, and can be safely copied/moved.
3232
*/
33-
typedef struct {
33+
typedef struct secp256k1_keypair {
3434
unsigned char data[96];
3535
} secp256k1_keypair;
3636

include/secp256k1_musig.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ extern "C" {
4040
* Guaranteed to be 197 bytes in size. No serialization and parsing functions
4141
* (yet).
4242
*/
43-
typedef struct {
43+
typedef struct secp256k1_musig_keyagg_cache {
4444
unsigned char data[197];
4545
} secp256k1_musig_keyagg_cache;
4646

@@ -56,7 +56,7 @@ typedef struct {
5656
* Copying this data structure can result in nonce reuse which will leak the
5757
* secret signing key.
5858
*/
59-
typedef struct {
59+
typedef struct secp256k1_musig_secnonce {
6060
unsigned char data[132];
6161
} secp256k1_musig_secnonce;
6262

@@ -65,7 +65,7 @@ typedef struct {
6565
* Guaranteed to be 132 bytes in size. Serialized and parsed with
6666
* `musig_pubnonce_serialize` and `musig_pubnonce_parse`.
6767
*/
68-
typedef struct {
68+
typedef struct secp256k1_musig_pubnonce {
6969
unsigned char data[132];
7070
} secp256k1_musig_pubnonce;
7171

@@ -74,7 +74,7 @@ typedef struct {
7474
* Guaranteed to be 132 bytes in size. Serialized and parsed with
7575
* `musig_aggnonce_serialize` and `musig_aggnonce_parse`.
7676
*/
77-
typedef struct {
77+
typedef struct secp256k1_musig_aggnonce {
7878
unsigned char data[132];
7979
} secp256k1_musig_aggnonce;
8080

@@ -84,7 +84,7 @@ typedef struct {
8484
* be secure. Guaranteed to be 133 bytes in size. No serialization and parsing
8585
* functions (yet).
8686
*/
87-
typedef struct {
87+
typedef struct secp256k1_musig_session {
8888
unsigned char data[133];
8989
} secp256k1_musig_session;
9090

@@ -93,7 +93,7 @@ typedef struct {
9393
* Guaranteed to be 36 bytes in size. Serialized and parsed with
9494
* `musig_partial_sig_serialize` and `musig_partial_sig_parse`.
9595
*/
96-
typedef struct {
96+
typedef struct secp256k1_musig_partial_sig {
9797
unsigned char data[36];
9898
} secp256k1_musig_partial_sig;
9999

include/secp256k1_recovery.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ extern "C" {
2121
* recoverability) will have identical representation, so they can be
2222
* memcmp'ed.
2323
*/
24-
typedef struct {
24+
typedef struct secp256k1_ecdsa_recoverable_signature {
2525
unsigned char data[65];
2626
} secp256k1_ecdsa_recoverable_signature;
2727

include/secp256k1_schnorrsig.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ SECP256K1_API const secp256k1_nonce_function_hardened secp256k1_nonce_function_b
7979
* secp256k1_nonce_function_bip340 is used, then ndata must be a
8080
* pointer to 32-byte auxiliary randomness as per BIP-340.
8181
*/
82-
typedef struct {
82+
typedef struct secp256k1_schnorrsig_extraparams {
8383
unsigned char magic[4];
8484
secp256k1_nonce_function_hardened noncefp;
8585
void *ndata;

0 commit comments

Comments
 (0)