forked from PAWPAW-Mirror/lib_xua
Since the functions are simple make them inline functions. This provides a small code size saving.
12 lines
535 B
Plaintext
12 lines
535 B
Plaintext
#include "queue.h"
|
|
|
|
// Force external definitions of inline functions.
|
|
extern inline int is_power_of_2(unsigned x);
|
|
extern inline void queue_init(queue_t &q, unsigned size);
|
|
extern inline int queue_is_empty(const queue_t &q);
|
|
extern inline int queue_is_full(const queue_t &q);
|
|
extern inline void queue_push_word(queue_t &q, unsigned array[], unsigned data);
|
|
extern inline unsigned queue_pop_word(queue_t &q, unsigned array[]);
|
|
extern inline unsigned queue_space(const queue_t &q);
|
|
extern inline unsigned queue_items(const queue_t &q);
|