mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-11-18 18:02:08 +08:00
refactor: change function definitions to const for improved performance and clarity
This commit is contained in:
@@ -45,7 +45,7 @@ enum Operation {
|
||||
}
|
||||
|
||||
impl Operation {
|
||||
fn timeout(&self) -> u64 {
|
||||
const fn timeout(&self) -> u64 {
|
||||
match self {
|
||||
Self::Upload => TIMEOUT_UPLOAD,
|
||||
Self::Download => TIMEOUT_DOWNLOAD,
|
||||
|
||||
Reference in New Issue
Block a user