summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzy <[email protected]>2023-09-21 10:23:21 +0000
committerzy <[email protected]>2023-09-21 10:23:21 +0000
commit1c075cdc25358b5d90d51200983117c7861692f3 (patch)
tree77e8ef89c4797247b61b0268f448b8e02f1d22ee
parent5f466f68b6761a5a31352c14371f540b1215a551 (diff)
tiemout_bind.rs: allow non_upper_case
-rw-r--r--src/timeout_bind.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/timeout_bind.rs b/src/timeout_bind.rs
index 98689f8..9d3b2eb 100644
--- a/src/timeout_bind.rs
+++ b/src/timeout_bind.rs
@@ -1,7 +1,7 @@
+#![allow(non_upper_case_globals)] // allow snake case just in this file
use std::ptr::null_mut;
use libc::{c_char, c_int, c_uint, c_ulonglong, c_void, FILE};
-
// TODO 检查条件编译选项
// 目前暂时全部注释掉
@@ -55,7 +55,7 @@ pub const TIMEOUT_DEFAULT: i32 = 0;
pub const TIMEOUT_INT: i32 = 1;
pub const TIMEOUT_ABS: i32 = 2;
-// TODO 宏定义 TIMEOUT_INITIALIZER timeout_setcb
+// 宏定义 TIMEOUT_INITIALIZER timeout_setcb
// 来自 TAILQ_ENTRY 宏
#[repr(C)]
@@ -66,7 +66,7 @@ pub struct timeout_TAILQ_ENTRY {
}
#[repr(C)]
-#[derive(Debug, Copy, Clone)]
+#[derive(Debug, Clone)]
pub struct timeout {
pub flags: c_int,
pub expires: timeout_t, /* absolute expiration time */