diff --git a/Marlin/src/pins/hc32f4/env_validate.h b/Marlin/src/pins/hc32f4/env_validate.h index 9bbc999fd6ee..b2db5e8b83e4 100644 --- a/Marlin/src/pins/hc32f4/env_validate.h +++ b/Marlin/src/pins/hc32f4/env_validate.h @@ -22,7 +22,7 @@ #ifndef ENV_VALIDATE_H #define ENV_VALIDATE_H -#ifndef ARDUINO_ARCH_HC32 +#if NOT_TARGET(ARDUINO_ARCH_HC32) #error "Oops! Select an HC32F460 board in 'Tools > Board.'" #endif