diff options
| author | Mikkel Thestrup <mithe24@student.sdu.dk> | 2025-12-04 18:51:54 +0100 |
|---|---|---|
| committer | Mikkel Thestrup <mithe24@student.sdu.dk> | 2025-12-04 18:51:54 +0100 |
| commit | 16527faeedfd8d3a27d3ac505d882f84bd34ed67 (patch) | |
| tree | 7cc110d89f728ebf6c2d2f6597b27bf2de702647 /src/vector.h | |
| parent | 5e27a37c6ce0c8b98951b3ecc9308961b47b955a (diff) | |
| download | cycle-detector-16527faeedfd8d3a27d3ac505d882f84bd34ed67.tar.gz cycle-detector-16527faeedfd8d3a27d3ac505d882f84bd34ed67.zip | |
Prefix macros to avoid macro name collisions. <3 header files
Diffstat (limited to '')
| -rw-r--r-- | src/vector.h | 8 |
1 files changed, 4 insertions, 4 deletions
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 <stddef.h> /** - * @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 |