From 948c655985dcbe6f8abcc7da850b91e8caa73080 Mon Sep 17 00:00:00 2001 From: Nicolas Schodet Date: Wed, 15 Dec 2010 00:24:38 +0100 Subject: digital/avr/common: add preprocessor tools --- digital/avr/modules/uart/uart_common.h | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'digital/avr/modules/uart') diff --git a/digital/avr/modules/uart/uart_common.h b/digital/avr/modules/uart/uart_common.h index 8f5a3af4..4704f59c 100644 --- a/digital/avr/modules/uart/uart_common.h +++ b/digital/avr/modules/uart/uart_common.h @@ -24,19 +24,16 @@ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * * }}} */ +#include "preproc.h" /* This symbol should be 0 or 1. */ #ifndef UART_N # error "uart: UART_N missing" #endif -/* Utility macros. */ -#define PASTE4_SUB(a, b, c, d) a ## b ## c ## d -#define PASTE4(a, b, c, d) PASTE4_SUB (a, b, c, d) - /* Port selection macros. */ -#define AC_UART(x) PASTE4(AC_UART, UART_N, _, x) -#define uart(x) PASTE4(uart, UART_N, _, x) +#define AC_UART(x) PREPROC_PASTE(AC_UART, UART_N, _, x) +#define uart(x) PREPROC_PASTE(uart, UART_N, _, x) /* Define uart symbols. */ #define uart_error uart (error) -- cgit v1.2.3