MCPcopy Create free account
hub / github.com/chyyuu/os_kernel_lab / from

Method from

user/src/io.rs:96–107  ·  view source on GitHub ↗
(mut v: u64)

Source from the content-addressed store, hash-verified

94
95impl From<u64> for InputEvent {
96 fn from(mut v: u64) -> Self {
97 let value = v as u32;
98 v >>= 32;
99 let code = v as u16;
100 v >>= 16;
101 let event_type = v as u16;
102 Self {
103 event_type,
104 code,
105 value,
106 }
107 }
108}
109
110impl InputEvent {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected