diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2011-10-09 22:50:12 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2011-10-09 22:50:12 -0700 |
commit | 41b7cf934f8af2a9fb622790bd28e2e8742ba380 (patch) | |
tree | b740872ac2ec8638bb0b2e296c8697ac021dbdda /lib.h | |
parent | 4c7f6f212eca77c2aae3d4bbc9b6be7f683cf260 (diff) | |
download | txr-41b7cf934f8af2a9fb622790bd28e2e8742ba380.tar.gz txr-41b7cf934f8af2a9fb622790bd28e2e8742ba380.tar.bz2 txr-41b7cf934f8af2a9fb622790bd28e2e8742ba380.zip |
One more swing at this with the axe.
* lib.h (wini, wref): New macros.
* stream.c (string_out_put_char): Rewritten with macros to eliminate
preprocessor #if test.
Diffstat (limited to 'lib.h')
-rw-r--r-- | lib.h | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -192,8 +192,12 @@ typedef struct wli wchli_t; #if LIT_ALIGN < 4 #define wli(lit) ((const wchli_t *) L"\0" L ## lit L"\0") +#define wini(ini) L"\0" L ## ini L"\0" +#define wref(arr) ((arr) + 1) #else #define wli(lit) ((const wchli_t *) L ## lit) +#define wini(ini) L ## ini +#define wref(arr) (arr) #endif INLINE val auto_str(const wchli_t *str) |