Skip to content

Commit 97d60cf

Browse files
committed
includes: add names to some structs.
1 parent ce9bb1c commit 97d60cf

File tree

4 files changed

+16
-16
lines changed

4 files changed

+16
-16
lines changed

src/ce/include/ti/real.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,11 @@ extern "C" {
2222
/**
2323
* @brief Structure of real variable type
2424
*/
25-
typedef struct { int8_t sign, exp; uint8_t mant[7]; } real_t;
25+
typedef struct real_t { int8_t sign, exp; uint8_t mant[7]; } real_t;
2626
/**
2727
* @brief Structure of complex variable type
2828
*/
29-
typedef struct { real_t real, imag; } cplx_t;
29+
typedef struct cplx_t { real_t real, imag; } cplx_t;
3030

3131
/** OP1 Variable */
3232
#define os_OP1 ((uint8_t*)0xD005F8)

src/ce/include/ti/vars.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -197,27 +197,27 @@ extern "C" {
197197
/**
198198
* @brief Structure of list variable type
199199
*/
200-
typedef struct { uint16_t dim; real_t items[1]; } list_t;
200+
typedef struct list_t { uint16_t dim; real_t items[1]; } list_t;
201201
/**
202202
* @brief Structure of complex list variable type
203203
*/
204-
typedef struct { uint16_t dim; cplx_t items[1]; } cplx_list_t;
204+
typedef struct cplx_list_t { uint16_t dim; cplx_t items[1]; } cplx_list_t;
205205
/**
206206
* @brief Structure of matrix variable type
207207
*/
208-
typedef struct { uint8_t cols, rows; real_t items[1]; } matrix_t;
208+
typedef struct matrix_t { uint8_t cols, rows; real_t items[1]; } matrix_t;
209209
/**
210210
* @brief Structure of string variable type
211211
*/
212-
typedef struct { uint16_t len; char data[1]; } string_t;
212+
typedef struct string_t { uint16_t len; char data[1]; } string_t;
213213
/**
214214
* @brief Structure of equation variable type
215215
*/
216-
typedef struct { uint16_t len; char data[1]; } equ_t;
216+
typedef struct equ_t { uint16_t len; char data[1]; } equ_t;
217217
/**
218218
* @brief Structure of miscellaneous variable type
219219
*/
220-
typedef struct { uint16_t size; uint8_t data[1]; } var_t;
220+
typedef struct var_t { uint16_t size; uint8_t data[1]; } var_t;
221221

222222
/**
223223
* Returns the size in bytes of free RAM that the user isn't using. A pointer is

src/fontlibc/fontlibc.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ typedef enum {
113113
* enforced. Check for malformed metadata!
114114
* @see fontlib_font_pack_t
115115
*/
116-
typedef struct {
116+
typedef struct fontlib_metadata_t {
117117
/**
118118
* Size of this struct, basically functions as a version field.
119119
* This does NOT include the lengths of the strings!
@@ -169,7 +169,7 @@ typedef struct {
169169
* it is probably not useful for C code to parse the width or bitmap data
170170
* directly.
171171
*/
172-
typedef struct {
172+
typedef struct fontlib_font_t {
173173
/**
174174
* Version ID
175175
* @note This must be zero or the font will be rejected as invalid.
@@ -269,7 +269,7 @@ typedef struct {
269269
* ti_Close(font_pack_file);
270270
* @endcode
271271
*/
272-
typedef struct {
272+
typedef struct fontlib_font_pack_t {
273273
/**
274274
* Must be "FONTPACK"
275275
* @note This is NOT null-terminated!

src/graphx/graphx.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ extern "C" {
7171
* Create at runtime (with uninitialized data) with gfx_MallocSprite(),
7272
* gfx_UninitedSprite(), or gfx_TempSprite().
7373
*/
74-
typedef struct {
74+
typedef struct gfx_sprite_t {
7575
uint8_t width; /**< Width of the image. */
7676
uint8_t height; /**< Height of the image. */
7777
uint8_t data[]; /**< Image data array. */
@@ -92,7 +92,7 @@ typedef struct {
9292
* Create at compile-time with a tool like
9393
* <a href="https://github.com/mateoconlechuga/convimg" target="_blank">convimg</a>.
9494
*/
95-
typedef struct {
95+
typedef struct gfx_rletsprite_t {
9696
uint8_t width; /**< Width of the image. */
9797
uint8_t height; /**< Height of the image. */
9898
uint8_t data[]; /**< Image data array. */
@@ -101,7 +101,7 @@ typedef struct {
101101
/**
102102
* A structure for working with 2D points.
103103
*/
104-
typedef struct {
104+
typedef struct gfx_point_t {
105105
int x; /**< x point. */
106106
int y; /**< y point. */
107107
} gfx_point_t;
@@ -111,7 +111,7 @@ typedef struct {
111111
*
112112
* @see gfx_GetClipRegion
113113
*/
114-
typedef struct {
114+
typedef struct gfx_region_t {
115115
int xmin; /**< Minimum x coordinate. */
116116
int ymin; /**< Minimum y coordinate. */
117117
int xmax; /**< Maximum x coordinate. */
@@ -123,7 +123,7 @@ typedef struct {
123123
*
124124
* @see gfx_Tilemap
125125
*/
126-
typedef struct {
126+
typedef struct gfx_tilemap_t {
127127
uint8_t *map; /**< Pointer to tilemap array. */
128128
gfx_sprite_t **tiles; /**< Pointer to tileset sprites for the tilemap. */
129129
uint8_t tile_height; /**< Individual tile height. */

0 commit comments

Comments
 (0)