@@ -118,18 +118,18 @@ fn completion_item_hash(item: &CompletionItem, is_ref_completion: bool) -> [u8;
118
118
u8:: from ( item. trigger_call_info ) ,
119
119
] ) ;
120
120
121
- hasher. update ( item. label . primary . len ( ) . to_le_bytes ( ) ) ;
121
+ hasher. update ( item. label . primary . len ( ) . to_ne_bytes ( ) ) ;
122
122
hasher. update ( & item. label . primary ) ;
123
123
124
124
hasher. update ( [ u8:: from ( item. label . detail_left . is_some ( ) ) ] ) ;
125
125
if let Some ( label_detail) = & item. label . detail_left {
126
- hasher. update ( label_detail. len ( ) . to_le_bytes ( ) ) ;
126
+ hasher. update ( label_detail. len ( ) . to_ne_bytes ( ) ) ;
127
127
hasher. update ( label_detail) ;
128
128
}
129
129
130
130
hasher. update ( [ u8:: from ( item. label . detail_right . is_some ( ) ) ] ) ;
131
131
if let Some ( label_detail) = & item. label . detail_right {
132
- hasher. update ( label_detail. len ( ) . to_le_bytes ( ) ) ;
132
+ hasher. update ( label_detail. len ( ) . to_ne_bytes ( ) ) ;
133
133
hasher. update ( label_detail) ;
134
134
}
135
135
@@ -140,15 +140,15 @@ fn completion_item_hash(item: &CompletionItem, is_ref_completion: bool) -> [u8;
140
140
// while not really making completion properties more unique as they are already.
141
141
142
142
let kind_tag = item. kind . tag ( ) ;
143
- hasher. update ( kind_tag. len ( ) . to_le_bytes ( ) ) ;
143
+ hasher. update ( kind_tag. len ( ) . to_ne_bytes ( ) ) ;
144
144
hasher. update ( kind_tag) ;
145
145
146
- hasher. update ( item. lookup . len ( ) . to_le_bytes ( ) ) ;
146
+ hasher. update ( item. lookup . len ( ) . to_ne_bytes ( ) ) ;
147
147
hasher. update ( & item. lookup ) ;
148
148
149
149
hasher. update ( [ u8:: from ( item. detail . is_some ( ) ) ] ) ;
150
150
if let Some ( detail) = & item. detail {
151
- hasher. update ( detail. len ( ) . to_le_bytes ( ) ) ;
151
+ hasher. update ( detail. len ( ) . to_ne_bytes ( ) ) ;
152
152
hasher. update ( detail) ;
153
153
}
154
154
@@ -162,12 +162,12 @@ fn completion_item_hash(item: &CompletionItem, is_ref_completion: bool) -> [u8;
162
162
CompletionItemRefMode :: Dereference => 2u8 ,
163
163
} ;
164
164
hasher. update ( [ discriminant] ) ;
165
- hasher. update ( u32:: from ( * text_size) . to_le_bytes ( ) ) ;
165
+ hasher. update ( u32:: from ( * text_size) . to_ne_bytes ( ) ) ;
166
166
}
167
167
168
- hasher. update ( item. import_to_add . len ( ) . to_le_bytes ( ) ) ;
168
+ hasher. update ( item. import_to_add . len ( ) . to_ne_bytes ( ) ) ;
169
169
for import_path in & item. import_to_add {
170
- hasher. update ( import_path. len ( ) . to_le_bytes ( ) ) ;
170
+ hasher. update ( import_path. len ( ) . to_ne_bytes ( ) ) ;
171
171
hasher. update ( import_path) ;
172
172
}
173
173
0 commit comments