From 16527faeedfd8d3a27d3ac505d882f84bd34ed67 Mon Sep 17 00:00:00 2001 From: Mikkel Thestrup Date: Thu, 4 Dec 2025 18:51:54 +0100 Subject: Prefix macros to avoid macro name collisions. <3 header files --- src/vector.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/vector.h') diff --git a/src/vector.h b/src/vector.h index 271fcff..7320442 100644 --- a/src/vector.h +++ b/src/vector.h @@ -13,22 +13,22 @@ #include /** - * @def INITAL_CAPACITY + * @def VECTOR_INITIAL_CAPACITY * @brief Initial capacity of a newly created vector. * @details The vector will be allocated with space for this many elements * when first created. This value is chosen to balance memory usage * and the number of early reallocations. */ -#define INITAL_CAPACITY 10 +#define VECTOR_INITIAL_CAPACITY 10 /** - * @def GROWTH_FACTOR + * @def VECTOR_GROWTH_FACTOR * @brief Multiplicative factor for vector capacity growth. * @details When the vector reaches capacity and needs to grow, the new * capacity is calculated as (current_capacity * GROWTH_FACTOR). * A factor of 2 provides good amortized performance. */ -#define GROWTH_FACTOR 2 +#define VECTOR_GROWTH_FACTOR 2 /** * @struct Vector -- cgit v1.2.3-70-g09d2