From 73a59a4e4527ce7aadfca81fd57e3105d4bf01d3 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Sun, 13 Mar 2016 22:15:01 -0700 Subject: [PATCH] Allow ENABLED(b) to work with "true" and "false" --- Marlin/macros.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Marlin/macros.h b/Marlin/macros.h index 4e974a56c..fe07b1883 100644 --- a/Marlin/macros.h +++ b/Marlin/macros.h @@ -17,9 +17,11 @@ // Macros to support option testing #define _CAT(a, ...) a ## __VA_ARGS__ -#define SWITCH_ENABLED_0 0 -#define SWITCH_ENABLED_1 1 -#define SWITCH_ENABLED_ 1 +#define SWITCH_ENABLED_false 0 +#define SWITCH_ENABLED_true 1 +#define SWITCH_ENABLED_0 0 +#define SWITCH_ENABLED_1 1 +#define SWITCH_ENABLED_ 1 #define ENABLED(b) _CAT(SWITCH_ENABLED_, b) #define DISABLED(b) (!_CAT(SWITCH_ENABLED_, b))