Skip to content

Commit

Permalink
add sign to the function, add to header file
Browse files Browse the repository at this point in the history
  • Loading branch information
BaseMax committed Jan 8, 2025
1 parent d4d6dde commit bf38ae8
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/generator_layout.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,15 @@

#include "generator_layout.h"

/**
*
* @function attribute_value_handler
* @brief Handles the value of a layout attribute and transforms it based on its type.
* @param attribute Pointer to the layout attribute structure.
* @param value The string value of the attribute to process.
* @return A dynamically allocated string containing the processed value, or NULL if the handler type is unsupported.
*
*/
char* attribute_value_handler(ast_layout_attribute_t* attribute, char* value)
{
switch (attribute->value_handler) {
Expand Down
11 changes: 11 additions & 0 deletions src/generator_layout.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,17 @@
#include "memory.h"
#include "string_buffer.h"

/**
*
* @function attribute_value_handler
* @brief Handles the value of a layout attribute and transforms it based on its type.
* @param attribute Pointer to the layout attribute structure.
* @param value The string value of the attribute to process.
* @return A dynamically allocated string containing the processed value, or NULL if the handler type is unsupported.
*
*/
char* attribute_value_handler(ast_layout_attribute_t* attribute, char* value);

/**
*
* @function generator_code_layout_value
Expand Down

0 comments on commit bf38ae8

Please sign in to comment.