Set compiler flag -pedantic
This commit is contained in:
parent
4dfb0d7edf
commit
1f668b6032
|
|
@ -7,7 +7,7 @@ OBJCOPY = avr-objcopy
|
|||
AVRDUDE ?= avrdude
|
||||
|
||||
# Compiler and linker flags
|
||||
CFLAGS = -Wall -std=c11 -Os
|
||||
CFLAGS = -Wall -pedantic -std=c11 -Os
|
||||
LDFLAGS =
|
||||
|
||||
# Target platform and programmer
|
||||
|
|
|
|||
|
|
@ -16,19 +16,19 @@
|
|||
static inline void BIT_SET(volatile uint8_t *target, uint8_t bit) __attribute__((always_inline));
|
||||
static inline void BIT_SET(volatile uint8_t *target, uint8_t bit){
|
||||
*target |= (1<<bit);
|
||||
};
|
||||
}
|
||||
|
||||
// set clear
|
||||
static inline void BIT_CLEAR(volatile uint8_t *target, uint8_t bit) __attribute__((always_inline));
|
||||
static inline void BIT_CLEAR(volatile uint8_t *target, uint8_t bit){
|
||||
*target &= ~(1<<bit);
|
||||
};
|
||||
}
|
||||
|
||||
// bit toogle
|
||||
static inline void BIT_TOGGLE(volatile uint8_t *target, uint8_t bit) __attribute__((always_inline));
|
||||
static inline void BIT_TOGGLE(volatile uint8_t *target, uint8_t bit){
|
||||
*target ^= (1<<bit);
|
||||
};
|
||||
}
|
||||
|
||||
// set bit by boolean
|
||||
static inline void BIT_BOOL_SET(volatile uint8_t *target, uint8_t bit, bool enable) __attribute__((always_inline));
|
||||
|
|
@ -38,6 +38,6 @@ static inline void BIT_BOOL_SET(volatile uint8_t *target, uint8_t bit, bool enab
|
|||
}else{
|
||||
BIT_CLEAR(target, bit);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
#endif /* BITIO_H_ */
|
||||
|
|
|
|||
Loading…
Reference in New Issue