refactor: use unchecked Utf8View in utf8 transformation
Internally we use only validated utf8 and unchecked performs much better and reduces unused error values.
This commit is contained in:
parent
2520a37a90
commit
68b17301cd
2 changed files with 8 additions and 15 deletions
|
|
@ -119,7 +119,7 @@ fn flush_input(self: *Self) !void {
|
|||
}
|
||||
|
||||
fn auto_detect_mode(self: *Self) Buffer.FindMode {
|
||||
return if (Buffer.unicode.is_lowercase(self.input_.items) catch return .exact) .case_folded else .exact;
|
||||
return if (Buffer.unicode.is_lowercase(self.input_.items)) .case_folded else .exact;
|
||||
}
|
||||
|
||||
fn cmd(self: *Self, name_: []const u8, ctx: command.Context) tp.result {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue