-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path_printf_internals.h
More file actions
40 lines (34 loc) · 1.67 KB
/
Copy path_printf_internals.h
File metadata and controls
40 lines (34 loc) · 1.67 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#ifndef PRINTF_INTERNALS_H
#define PRINTF_INTERNALS_H
#include <assert.h> /* assert */
#include <ctype.h> /* isdigit, islower*/
#include <inttypes.h> /* imaxabs, fixed width types */
#include <stdarg.h> /* va_list */
#include <stdbool.h> /* bool */
#include <stddef.h> /* ptrdiff_t, size_t */
#include <stdlib.h> /* malloc */
#include <unistd.h> /* write */
#include "_printf_typedefs.h"
#include "buffer_object.h"
#include "string_object.h"
#include "util_functions.h"
#define PRINTF_BUFFER_LENGTH (1024U)
int format_handler(va_list args, string *format, char_arr *buffer);
int format_integers(uintmax_t num, char_arr *buffer, modifiers mods);
void init_working_string(
char_arr *const wip_str, const modifiers mods, const intmax_t str_len);
int print_binary(va_list args, char_arr *buffer, modifiers mods);
int print_character(va_list args, char_arr *buffer, modifiers mods);
int print_hexa_lower(va_list args, char_arr *buffer, modifiers mods);
int print_hexa_upper(va_list args, char_arr *buffer, modifiers mods);
int print_int_di(va_list args, char_arr *buffer, modifiers mods);
int print_int_u(va_list args, char_arr *buffer, modifiers mods);
int print_oct(va_list args, char_arr *buffer, modifiers mods);
int print_percent(va_list args, char_arr *buffer, modifiers mods);
int print_ptr(va_list args, char_arr *buffer, modifiers mods);
int print_reversed(va_list args, char_arr *buffer, modifiers mods);
int print_rot13(va_list args, char_arr *buffer, modifiers mods);
int print_str(va_list args, char_arr *buffer, modifiers mods);
int print_STR(va_list args, char_arr *buffer, modifiers mods);
int print_unknown(string *format, char_arr *buffer);
#endif /* PRINTF_INTERNALS_H */