Skip to content
This repository was archived by the owner on Mar 11, 2025. It is now read-only.

Commit b3f5a4a

Browse files
committed
use repr(u8) for enums in token lending
1 parent c5e7e42 commit b3f5a4a

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

token-lending/program/src/pyth.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ pub struct AccKey {
2121
}
2222

2323
#[derive(PartialEq, Copy, Clone)]
24-
#[repr(C)]
24+
#[repr(u8)]
2525
pub enum AccountType {
2626
Unknown,
2727
Mapping,
@@ -30,7 +30,7 @@ pub enum AccountType {
3030
}
3131

3232
#[derive(PartialEq, Copy, Clone)]
33-
#[repr(C)]
33+
#[repr(u8)]
3434
pub enum PriceStatus {
3535
Unknown,
3636
Trading,
@@ -39,7 +39,7 @@ pub enum PriceStatus {
3939
}
4040

4141
#[derive(PartialEq, Copy, Clone)]
42-
#[repr(C)]
42+
#[repr(u8)]
4343
pub enum CorpAction {
4444
NoCorpAct,
4545
}
@@ -63,7 +63,7 @@ pub struct PriceComp {
6363
}
6464

6565
#[derive(PartialEq, Copy, Clone)]
66-
#[repr(C)]
66+
#[repr(u8)]
6767
pub enum PriceType {
6868
Unknown,
6969
Price,

0 commit comments

Comments
 (0)