Add DString init.

This commit is contained in:
Christoffer Lerno
2023-03-06 09:12:52 +01:00
parent a4231823df
commit 9eee250b10
21 changed files with 402 additions and 402 deletions

View File

@@ -9,7 +9,7 @@ enum Foo
fn void print_pages()
{
mem::temp_allocator().print_pages(io::stdout());
mem::temp().print_pages(io::stdout());
}
fn void setstring(char* dst, String str)
@@ -73,8 +73,8 @@ fn void main()
{
io::printf("Talloc: %p\n", (void*)tmalloc(22));
};
testAllocator(mem::temp_allocator(), 126);
testAllocator(mem::temp_allocator(), 12600);
testAllocator(mem::temp(), 126);
testAllocator(mem::temp(), 12600);
ArenaAllocator aa;
aa.init(&&char[1024] {});
testAllocator(&aa, 126);