Make CommitmentLevel constructors const (#27367)

make CommitmentLevel constructors const
This commit is contained in:
Florian Hartwig 2022-08-31 21:20:53 +02:00 committed by GitHub
parent 2e7dc64dbd
commit 12f921386f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 3 deletions

View File

@ -60,19 +60,19 @@ impl CommitmentConfig {
}
}
pub fn finalized() -> Self {
pub const fn finalized() -> Self {
Self {
commitment: CommitmentLevel::Finalized,
}
}
pub fn confirmed() -> Self {
pub const fn confirmed() -> Self {
Self {
commitment: CommitmentLevel::Confirmed,
}
}
pub fn processed() -> Self {
pub const fn processed() -> Self {
Self {
commitment: CommitmentLevel::Processed,
}