mirror of
https://github.com/oven-sh/bun
synced 2026-02-10 02:48:50 +00:00
Start time performance improvements to build tools (#3797)
* Make os.cpus() faster on Linux * Fix crash See https://github.com/ziglang/zig/issues/16540 * Handle watcher_count == 0 * Add assertion * Clean up lifetimes of fs watcher a little * ✂️ * Use `errdefer` * Make the error better * Make os.cpus() more lazy * Please don't translate-c on the entire C standard library * immediately closing works correctly is still bug * ops * fmt+fixeup * add back verbose * free instead of destroy * remove destroy option for watcher tasks * flush verbose and add debug log * fixup files * use log for debug --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> Co-authored-by: cirospaciari <ciro.spaciari@gmail.com>
This commit is contained in:
@@ -672,15 +672,7 @@ pub fn startsWith(self: string, str: string) bool {
|
||||
return false;
|
||||
}
|
||||
|
||||
var i: usize = 0;
|
||||
while (i < str.len) {
|
||||
if (str[i] != self[i]) {
|
||||
return false;
|
||||
}
|
||||
i += 1;
|
||||
}
|
||||
|
||||
return true;
|
||||
return eqlLong(self[0..str.len], str, false);
|
||||
}
|
||||
|
||||
pub inline fn endsWith(self: string, str: string) bool {
|
||||
|
||||
Reference in New Issue
Block a user