aboutsummaryrefslogtreecommitdiff
path: root/src/linker.zig
diff options
context:
space:
mode:
authorGravatar Alex Lam S.L <alexlamsl@gmail.com> 2023-01-10 15:35:20 +0200
committerGravatar GitHub <noreply@github.com> 2023-01-10 05:35:20 -0800
commit270b07e85e82b46491cc713fb2a5bb973d3de4f6 (patch)
treeb8071eaf835f2aefb8ee95c68f9002d84b7b5761 /src/linker.zig
parentb458abedbb865461005757cac5ea2b458249ef25 (diff)
downloadbun-270b07e85e82b46491cc713fb2a5bb973d3de4f6.tar.gz
bun-270b07e85e82b46491cc713fb2a5bb973d3de4f6.tar.zst
bun-270b07e85e82b46491cc713fb2a5bb973d3de4f6.zip
use `strings.hasPrefixComptime()` (#1755)
Diffstat (limited to 'src/linker.zig')
-rw-r--r--src/linker.zig2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/linker.zig b/src/linker.zig
index b9ce293cd..3d53dc1b1 100644
--- a/src/linker.zig
+++ b/src/linker.zig
@@ -304,7 +304,7 @@ pub const Linker = struct {
}
}
- if (import_record.path.text.len > 4 and strings.eqlComptimeIgnoreLen(import_record.path.text[0.."bun:".len], "bun:")) {
+ if (strings.hasPrefixComptime(import_record.path.text, "bun:")) {
import_record.path = Fs.Path.init(import_record.path.text["bun:".len..]);
import_record.path.namespace = "bun";