changed allocator to take context.allocator

This commit is contained in:
Simon Kellet 2026-03-12 13:12:54 +00:00
parent 37c60d901f
commit 4a6c705e77

View File

@ -1,6 +1,5 @@
package main
import "base:runtime"
import "core:fmt"
import "core:os"
import "core:strings"
@ -13,7 +12,10 @@ CSS_PREFIX :: "<head><link rel=\"stylesheet\" href=\"./css/style.css\">\n"
MASTODON_PREFIX :: "<a rel=me href=https://linuxrocks.online/@simonkellet></a>\n"
walk_tree_and_get_md_names :: proc(path: string, allocator: runtime.Allocator) -> [dynamic]string {
walk_tree_and_get_md_names :: proc(
path: string,
allocator := context.allocator,
) -> [dynamic]string {
files := make([dynamic]string, allocator)
@ -73,7 +75,7 @@ walk_tree :: proc(path: string) -> []u8 {
parse_file_md_to_html :: proc(
filename: string,
allocator: runtime.Allocator,
allocator := context.allocator,
) -> (
parsed: string,
err: os.Error,