@@ -236,14 +236,14 @@ pub fn process_instruction(
236
236
let to = next_keyed_account ( keyed_accounts_iter) ?;
237
237
transfer_lamports ( from, to, lamports)
238
238
}
239
- SystemInstruction :: NonceAdvance => {
239
+ SystemInstruction :: AdvanceNonceAccount => {
240
240
let me = & mut next_keyed_account ( keyed_accounts_iter) ?;
241
241
me. nonce_advance (
242
242
& RecentBlockhashes :: from_keyed_account ( next_keyed_account ( keyed_accounts_iter) ?) ?,
243
243
& signers,
244
244
)
245
245
}
246
- SystemInstruction :: NonceWithdraw ( lamports) => {
246
+ SystemInstruction :: WithdrawNonceAccount ( lamports) => {
247
247
let me = & mut next_keyed_account ( keyed_accounts_iter) ?;
248
248
let to = & mut next_keyed_account ( keyed_accounts_iter) ?;
249
249
me. nonce_withdraw (
@@ -254,15 +254,15 @@ pub fn process_instruction(
254
254
& signers,
255
255
)
256
256
}
257
- SystemInstruction :: NonceInitialize ( authorized) => {
257
+ SystemInstruction :: InitializeNonceAccount ( authorized) => {
258
258
let me = & mut next_keyed_account ( keyed_accounts_iter) ?;
259
259
me. nonce_initialize (
260
260
& authorized,
261
261
& RecentBlockhashes :: from_keyed_account ( next_keyed_account ( keyed_accounts_iter) ?) ?,
262
262
& Rent :: from_keyed_account ( next_keyed_account ( keyed_accounts_iter) ?) ?,
263
263
)
264
264
}
265
- SystemInstruction :: NonceAuthorize ( nonce_authority) => {
265
+ SystemInstruction :: AuthorizeNonceAccount ( nonce_authority) => {
266
266
let me = & mut next_keyed_account ( keyed_accounts_iter) ?;
267
267
me. nonce_authorize ( & nonce_authority, & signers)
268
268
}
@@ -902,7 +902,7 @@ mod tests {
902
902
super :: process_instruction(
903
903
& Pubkey :: default ( ) ,
904
904
& mut [ ] ,
905
- & serialize( & SystemInstruction :: NonceAdvance ) . unwrap( )
905
+ & serialize( & SystemInstruction :: AdvanceNonceAccount ) . unwrap( )
906
906
) ,
907
907
Err ( InstructionError :: NotEnoughAccountKeys ) ,
908
908
) ;
@@ -918,7 +918,7 @@ mod tests {
918
918
true ,
919
919
& mut Account :: default ( ) ,
920
920
) , ] ,
921
- & serialize( & SystemInstruction :: NonceAdvance ) . unwrap( ) ,
921
+ & serialize( & SystemInstruction :: AdvanceNonceAccount ) . unwrap( ) ,
922
922
) ,
923
923
Err ( InstructionError :: NotEnoughAccountKeys ) ,
924
924
) ;
@@ -937,7 +937,7 @@ mod tests {
937
937
& mut Account :: default ( ) ,
938
938
) ,
939
939
] ,
940
- & serialize( & SystemInstruction :: NonceAdvance ) . unwrap( ) ,
940
+ & serialize( & SystemInstruction :: AdvanceNonceAccount ) . unwrap( ) ,
941
941
) ,
942
942
Err ( InstructionError :: InvalidArgument ) ,
943
943
) ;
@@ -964,7 +964,7 @@ mod tests {
964
964
& mut sysvar:: rent:: create_account ( 1 , & Rent :: free ( ) ) ,
965
965
) ,
966
966
] ,
967
- & serialize ( & SystemInstruction :: NonceInitialize ( Pubkey :: default ( ) ) ) . unwrap ( ) ,
967
+ & serialize ( & SystemInstruction :: InitializeNonceAccount ( Pubkey :: default ( ) ) ) . unwrap ( ) ,
968
968
)
969
969
. unwrap ( ) ;
970
970
assert_eq ! (
@@ -981,7 +981,7 @@ mod tests {
981
981
) ,
982
982
) ,
983
983
] ,
984
- & serialize( & SystemInstruction :: NonceAdvance ) . unwrap( ) ,
984
+ & serialize( & SystemInstruction :: AdvanceNonceAccount ) . unwrap( ) ,
985
985
) ,
986
986
Ok ( ( ) ) ,
987
987
) ;
@@ -1006,7 +1006,7 @@ mod tests {
1006
1006
super :: process_instruction(
1007
1007
& Pubkey :: default ( ) ,
1008
1008
& mut [ ] ,
1009
- & serialize( & SystemInstruction :: NonceWithdraw ( 42 ) ) . unwrap( ) ,
1009
+ & serialize( & SystemInstruction :: WithdrawNonceAccount ( 42 ) ) . unwrap( ) ,
1010
1010
) ,
1011
1011
Err ( InstructionError :: NotEnoughAccountKeys ) ,
1012
1012
) ;
@@ -1022,7 +1022,7 @@ mod tests {
1022
1022
true ,
1023
1023
& mut Account :: default ( ) ,
1024
1024
) , ] ,
1025
- & serialize( & SystemInstruction :: NonceWithdraw ( 42 ) ) . unwrap( ) ,
1025
+ & serialize( & SystemInstruction :: WithdrawNonceAccount ( 42 ) ) . unwrap( ) ,
1026
1026
) ,
1027
1027
Err ( InstructionError :: NotEnoughAccountKeys ) ,
1028
1028
) ;
@@ -1042,7 +1042,7 @@ mod tests {
1042
1042
& mut Account :: default ( ) ,
1043
1043
) ,
1044
1044
] ,
1045
- & serialize( & SystemInstruction :: NonceWithdraw ( 42 ) ) . unwrap( ) ,
1045
+ & serialize( & SystemInstruction :: WithdrawNonceAccount ( 42 ) ) . unwrap( ) ,
1046
1046
) ,
1047
1047
Err ( InstructionError :: InvalidArgument ) ,
1048
1048
) ;
@@ -1070,7 +1070,7 @@ mod tests {
1070
1070
) ,
1071
1071
KeyedAccount :: new( & sysvar:: rent:: id( ) , false , & mut Account :: default ( ) , ) ,
1072
1072
] ,
1073
- & serialize( & SystemInstruction :: NonceWithdraw ( 42 ) ) . unwrap( ) ,
1073
+ & serialize( & SystemInstruction :: WithdrawNonceAccount ( 42 ) ) . unwrap( ) ,
1074
1074
) ,
1075
1075
Err ( InstructionError :: InvalidArgument ) ,
1076
1076
) ;
@@ -1102,7 +1102,7 @@ mod tests {
1102
1102
& mut sysvar:: rent:: create_account( 1 , & Rent :: free( ) )
1103
1103
) ,
1104
1104
] ,
1105
- & serialize( & SystemInstruction :: NonceWithdraw ( 42 ) ) . unwrap( ) ,
1105
+ & serialize( & SystemInstruction :: WithdrawNonceAccount ( 42 ) ) . unwrap( ) ,
1106
1106
) ,
1107
1107
Ok ( ( ) ) ,
1108
1108
) ;
@@ -1114,7 +1114,7 @@ mod tests {
1114
1114
super :: process_instruction(
1115
1115
& Pubkey :: default ( ) ,
1116
1116
& mut [ ] ,
1117
- & serialize( & SystemInstruction :: NonceInitialize ( Pubkey :: default ( ) ) ) . unwrap( ) ,
1117
+ & serialize( & SystemInstruction :: InitializeNonceAccount ( Pubkey :: default ( ) ) ) . unwrap( ) ,
1118
1118
) ,
1119
1119
Err ( InstructionError :: NotEnoughAccountKeys ) ,
1120
1120
) ;
@@ -1130,7 +1130,7 @@ mod tests {
1130
1130
true ,
1131
1131
& mut nonce_state:: create_account( 1_000_000 ) ,
1132
1132
) , ] ,
1133
- & serialize( & SystemInstruction :: NonceInitialize ( Pubkey :: default ( ) ) ) . unwrap( ) ,
1133
+ & serialize( & SystemInstruction :: InitializeNonceAccount ( Pubkey :: default ( ) ) ) . unwrap( ) ,
1134
1134
) ,
1135
1135
Err ( InstructionError :: NotEnoughAccountKeys ) ,
1136
1136
) ;
@@ -1153,7 +1153,7 @@ mod tests {
1153
1153
& mut Account :: default ( ) ,
1154
1154
) ,
1155
1155
] ,
1156
- & serialize( & SystemInstruction :: NonceInitialize ( Pubkey :: default ( ) ) ) . unwrap( ) ,
1156
+ & serialize( & SystemInstruction :: InitializeNonceAccount ( Pubkey :: default ( ) ) ) . unwrap( ) ,
1157
1157
) ,
1158
1158
Err ( InstructionError :: InvalidArgument ) ,
1159
1159
) ;
@@ -1180,7 +1180,7 @@ mod tests {
1180
1180
) ,
1181
1181
KeyedAccount :: new( & sysvar:: rent:: id( ) , false , & mut Account :: default ( ) , ) ,
1182
1182
] ,
1183
- & serialize( & SystemInstruction :: NonceInitialize ( Pubkey :: default ( ) ) ) . unwrap( ) ,
1183
+ & serialize( & SystemInstruction :: InitializeNonceAccount ( Pubkey :: default ( ) ) ) . unwrap( ) ,
1184
1184
) ,
1185
1185
Err ( InstructionError :: InvalidArgument ) ,
1186
1186
) ;
@@ -1211,7 +1211,7 @@ mod tests {
1211
1211
& mut sysvar:: rent:: create_account( 1 , & Rent :: free( ) )
1212
1212
) ,
1213
1213
] ,
1214
- & serialize( & SystemInstruction :: NonceInitialize ( Pubkey :: default ( ) ) ) . unwrap( ) ,
1214
+ & serialize( & SystemInstruction :: InitializeNonceAccount ( Pubkey :: default ( ) ) ) . unwrap( ) ,
1215
1215
) ,
1216
1216
Ok ( ( ) ) ,
1217
1217
) ;
@@ -1238,14 +1238,14 @@ mod tests {
1238
1238
& mut sysvar:: rent:: create_account ( 1 , & Rent :: free ( ) ) ,
1239
1239
) ,
1240
1240
] ,
1241
- & serialize ( & SystemInstruction :: NonceInitialize ( Pubkey :: default ( ) ) ) . unwrap ( ) ,
1241
+ & serialize ( & SystemInstruction :: InitializeNonceAccount ( Pubkey :: default ( ) ) ) . unwrap ( ) ,
1242
1242
)
1243
1243
. unwrap ( ) ;
1244
1244
assert_eq ! (
1245
1245
super :: process_instruction(
1246
1246
& Pubkey :: default ( ) ,
1247
1247
& mut [ KeyedAccount :: new( & Pubkey :: default ( ) , true , & mut nonce_acc, ) , ] ,
1248
- & serialize( & SystemInstruction :: NonceAuthorize ( Pubkey :: default ( ) , ) ) . unwrap( ) ,
1248
+ & serialize( & SystemInstruction :: AuthorizeNonceAccount ( Pubkey :: default ( ) , ) ) . unwrap( ) ,
1249
1249
) ,
1250
1250
Ok ( ( ) ) ,
1251
1251
) ;
0 commit comments