mirror of
https://github.com/oven-sh/bun
synced 2026-02-09 18:38:55 +00:00
asopdk
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
const std = @import("std");
|
||||
const expect = std.testing.expect;
|
||||
|
||||
const JavascriptString = @import("ast/base.zig").JavascriptString;
|
||||
|
||||
usingnamespace @import("string_types.zig");
|
||||
|
||||
pub fn containsChar(self: string, char: u8) bool {
|
||||
@@ -34,3 +36,7 @@ pub fn index(self: string, str: string) i32 {
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
pub fn eqlUtf16(comptime self: string, other: JavascriptString) bool {
|
||||
return std.mem.eql(u16, std.unicode.utf8ToUtf16LeStringLiteral(self), other);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user