From 8fddcd4fa3ce86f46a712b040cd20818b435642f Mon Sep 17 00:00:00 2001 From: lohhiiccc <96543753+lohhiiccc@users.noreply.github.com> Date: Mon, 12 Jan 2026 17:38:48 +0100 Subject: [PATCH] docs: update function reference links to use anchor fragments in headers --- includes/cli.h.md | 4 ++-- includes/internal/map_internal.h.md | 2 +- includes/internal/transpile_internal.h.md | 8 ++++---- includes/io.h.md | 4 ++-- includes/map.h.md | 8 ++++---- includes/transpile.h.md | 2 +- includes/utils.h.md | 10 +++++----- includes/validator.h.md | 2 +- 8 files changed, 20 insertions(+), 20 deletions(-) diff --git a/includes/cli.h.md b/includes/cli.h.md index d2aa5ef..a243ff1 100644 --- a/includes/cli.h.md +++ b/includes/cli.h.md @@ -24,14 +24,14 @@ typedef struct s_args ``` ## Functions -### [`cli_parse`](/srcs/cli/cli.c.md) +### [`cli_parse`](/srcs/cli/cli.c.md#cli_parse) Parses command-line arguments and populates the t_args structure. ```c int8_t cli_parse(t_args *args, int32_t argc, char **argv); ``` -### [`cli_print_help`](/srcs/cli/help.c.md) +### [`cli_print_help`](/srcs/cli/help.c.md#cli_printhelp) Prints help information for the command-line interface. ```c void diff --git a/includes/internal/map_internal.h.md b/includes/internal/map_internal.h.md index 9b1bf8e..3dfc1f7 100644 --- a/includes/internal/map_internal.h.md +++ b/includes/internal/map_internal.h.md @@ -13,7 +13,7 @@ ## Functions -### [`map_grow`](/srcs/map/core.c.md) +### [`map_grow`](/srcs/map/core.c.md#map_grow) Grows the map's capacity when needed. ```c int8_t diff --git a/includes/internal/transpile_internal.h.md b/includes/internal/transpile_internal.h.md index 22fbad8..3196c7a 100644 --- a/includes/internal/transpile_internal.h.md +++ b/includes/internal/transpile_internal.h.md @@ -32,28 +32,28 @@ typedef struct s_state ## Functions -### [`state_init`](/srcs/transpile/state.c.md) +### [`state_init`](/srcs/transpile/state.c.md#state_init) Initializes the transpilation state. ```c void state_init(t_state *s, FILE *in, FILE *out, const char *ext, t_map *map); ``` -### [`handle_fence_open`](/srcs/transpile/fence.c.md) +### [`handle_fence_open`](/srcs/transpile/fence.c.md#handle_fence_open) Handles the opening of a code fence in the input. ```c int8_t handle_fence_open(t_state *s, char *line); ``` -### [`handle_fence_close`](/srcs/transpile/fence.c.md) +### [`handle_fence_close`](/srcs/transpile/fence.c.md#handle_fence_open) Handles the closing of a code fence in the input. ```c int8_t handle_fence_close(t_state *s); ``` -### [`handle_line`](/srcs/transpile/code.c.md) +### [`handle_code_line`](/srcs/transpile/code.c.md#handle_code_line) Handles a regular line of code in the input. ```c int8_t diff --git a/includes/io.h.md b/includes/io.h.md index df41754..a07b114 100644 --- a/includes/io.h.md +++ b/includes/io.h.md @@ -20,14 +20,14 @@ typedef struct s_io ## Functions -### [`io_open`](/srcs/io/streams.c.md) +### [`io_open`](/srcs/io/streams.c.md#io_open) Opens input and output streams based on provided file paths. ```c int8_t io_open(t_io *io, const char *input_path, const char *output_path); ``` -### [`io_close`](/srcs/io/streams.c.md) +### [`io_close`](/srcs/io/streams.c.md#io_close) Closes the input and output streams if they are not stdin or stdout. ```c void diff --git a/includes/map.h.md b/includes/map.h.md index b62bcb2..0f5ed63 100644 --- a/includes/map.h.md +++ b/includes/map.h.md @@ -37,14 +37,14 @@ typedef struct s_map ## Functions -### [`map_init`](/srcs/map/core.c.md) +### [`map_init`](/srcs/map/core.c.md#map_init) Initialize a mapping structure. ```c void map_init(t_map *map); ``` -### [`map_add`](/srcs/map/core.c.md) +### [`map_add`](/srcs/map/core.c.md#map_add) Add a new mapping range to the mapping structure. ```c void @@ -52,14 +52,14 @@ map_add(t_map *map, uint32_t src_start, uint32_t src_end, uint32_t dst_start, uint32_t dst_end); ``` -### [`map_write`](/srcs/map/io.c.md) +### [`map_write`](/srcs/map/io.c.md#map_write) Write the mapping information to a file. ```c int8_t map_write(t_map *map, const char *path, const char *source, const char *target); ``` -### [`map_free`](/srcs/map/core.c.md) +### [`map_free`](/srcs/map/core.c.md#map_free) Free the resources associated with the mapping structure. ```c void diff --git a/includes/transpile.h.md b/includes/transpile.h.md index 7a103fe..681a92d 100644 --- a/includes/transpile.h.md +++ b/includes/transpile.h.md @@ -11,7 +11,7 @@ ``` ## Functions -### [`transpile`](/srcs/transpile/core.c.md) +### [`transpile`](/srcs/transpile/core.c.md#transpile) ```c int8_t transpile(FILE *in, FILE *out, const char *ext, t_map *map); diff --git a/includes/utils.h.md b/includes/utils.h.md index f10ad71..2490ab8 100644 --- a/includes/utils.h.md +++ b/includes/utils.h.md @@ -10,35 +10,35 @@ ``` ## Functions -### [`read_line`](/srcs/utils/io/read_line.c.md) +### [`read_line`](/srcs/utils/io/read_line.c.md#read_line) Get a line from a file. ```c char * read_line(FILE *f); ``` -### [`starts_with`](/srcs/utils/string/starts_with.c.md) +### [`starts_with`](/srcs/utils/string/starts_with.c.md#starts_with) Check if a string starts with a given prefix. ```c int8_t starts_with(const char *str, const char *prefix); ``` -### [`extract_fence_ext`](/srcs/utils/string/extract_fence_ext.c.md) +### [`extract_fence_ext`](/srcs/utils/string/extract_fence_ext.c.md#extract_fence_ext) Extract the extension from a fence string. ```c char * extract_fence_ext(const char *fence); ``` -### [`extract_file_ext`](/srcs/utils/string/extract_file_ext.c.md) +### [`extract_file_ext`](/srcs/utils/string/extract_file_ext.c.md#extract_file_ext) Extract the file extension from a file path. ```c const char * extract_file_ext(const char *path); ``` -### [`infer_ext_from_filename`](/srcs/utils/string/infer_ext_from_filename.c.md) +### [`infer_ext_from_filename`](/srcs/utils/string/infer_ext_from_filename.c.md#infer_ext_from_filename) Infer the file extension from a filename. ```c const char * diff --git a/includes/validator.h.md b/includes/validator.h.md index 1d33b77..04cb31e 100644 --- a/includes/validator.h.md +++ b/includes/validator.h.md @@ -10,7 +10,7 @@ ## Functions -### [`validator_validate_args`](/srcs/validator/validator.c.md) +### [`validator_validate_args`](/srcs/validator/validator.c.md#validator_validate_args) This function checks and validates the content of the `t_args` structure, ```c int8_t