module internal.types.str
¶
Source: stdlib/internal/types/str.codon
strlen(a: cobj)
@pure Function has no side effects and returns same value for same inputs @C Function is external C function ¶
str
@extend Class is extended to add given methods ¶
Magic methods¶
__new__(l: int, p: Ptr[byte])
@internal Function is compiler-generated ¶
__new__(p: Ptr[byte], l: int)
@overload Function is overloaded ¶
__new__()
@overload Function is overloaded ¶
__new__(what)
@overload Function is overloaded ¶
__str__(what: str)
¶
__len__(self)
¶
__bool__(self)
¶
__copy__(self)
¶
__deepcopy__(self)
¶
__ptrcopy__(self)
¶
__add__(self, other: str)
¶
__eq__(self, other: str)
¶
__match__(self, obj: str)
¶
__ne__(self, other: str)
¶
__prefix_b__(s: str, N: Literal[int])
¶
Methods¶
memcpy(dest: Ptr[byte], src: Ptr[byte], len: int)
@llvm Function is implemented with inline LLVM IR ¶
declare void @llvm.memcpy.p0i8.p0i8.i64(ptr %dest, ptr %src, i64 %len, i32 %align, i1 %isvolatile)
call void @llvm.memcpy.p0i8.p0i8.i64(ptr %dest, ptr %src, i64 %len, i32 0, i1 false)
ret {} {}
memmove(dest: Ptr[byte], src: Ptr[byte], len: int)
@llvm Function is implemented with inline LLVM IR ¶
declare void @llvm.memmove.p0i8.p0i8.i64(ptr %dest, ptr %src, i64 %len, i32 %align, i1 %isvolatile)
call void @llvm.memmove.p0i8.p0i8.i64(ptr %dest, ptr %src, i64 %len, i32 0, i1 false)
ret {} {}
memset(dest: Ptr[byte], val: byte, len: int)
@llvm Function is implemented with inline LLVM IR ¶
declare void @llvm.memset.p0i8.i64(ptr %dest, i8 %val, i64 %len, i32 %align, i1 %isvolatile)
call void @llvm.memset.p0i8.i64(ptr %dest, i8 %val, i64 %len, i32 0, i1 false)
ret {} {}