Mark method as constant

Allow external const calls to access this method
This commit is contained in:
yancy 2025-05-08 16:53:30 -05:00
parent 3a6a399f48
commit fd90c8782a
1 changed files with 1 additions and 1 deletions

View File

@ -118,7 +118,7 @@ impl FeeRate {
/// [`NumOpResult::Error`] if an overflow occurred.
///
/// This is equivalent to `Self::checked_mul_by_weight()`.
pub fn to_fee(self, weight: Weight) -> NumOpResult<Amount> {
pub const fn to_fee(self, weight: Weight) -> NumOpResult<Amount> {
self.checked_mul_by_weight(weight)
}