Set compiler flag -pedantic

This commit is contained in:
Lexi / Zoe 2021-04-17 02:36:31 +02:00
parent 4dfb0d7edf
commit 1f668b6032
Signed by: binaryDiv
GPG Key ID: F8D4956E224DA232
2 changed files with 5 additions and 5 deletions

View File

@ -7,7 +7,7 @@ OBJCOPY = avr-objcopy
AVRDUDE ?= avrdude AVRDUDE ?= avrdude
# Compiler and linker flags # Compiler and linker flags
CFLAGS = -Wall -std=c11 -Os CFLAGS = -Wall -pedantic -std=c11 -Os
LDFLAGS = LDFLAGS =
# Target platform and programmer # Target platform and programmer

View File

@ -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) __attribute__((always_inline));
static inline void BIT_SET(volatile uint8_t *target, uint8_t bit){ static inline void BIT_SET(volatile uint8_t *target, uint8_t bit){
*target |= (1<<bit); *target |= (1<<bit);
}; }
// set clear // 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) __attribute__((always_inline));
static inline void BIT_CLEAR(volatile uint8_t *target, uint8_t bit){ static inline void BIT_CLEAR(volatile uint8_t *target, uint8_t bit){
*target &= ~(1<<bit); *target &= ~(1<<bit);
}; }
// bit toogle // 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) __attribute__((always_inline));
static inline void BIT_TOGGLE(volatile uint8_t *target, uint8_t bit){ static inline void BIT_TOGGLE(volatile uint8_t *target, uint8_t bit){
*target ^= (1<<bit); *target ^= (1<<bit);
}; }
// set bit by boolean // set bit by boolean
static inline void BIT_BOOL_SET(volatile uint8_t *target, uint8_t bit, bool enable) __attribute__((always_inline)); 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{ }else{
BIT_CLEAR(target, bit); BIT_CLEAR(target, bit);
} }
}; }
#endif /* BITIO_H_ */ #endif /* BITIO_H_ */