All~ CHECK_this_length macro expands to multiple statements making it unsafe to use in a single line `if` statement (as is happening near line 335). This fixes the macro using the standard `do { } while (0)` macro trick.
Matt
Index: src/main/sprintf.c =================================================================== --- src/main/sprintf.c (revision 70421) +++ src/main/sprintf.c (working copy) @@ -262,11 +262,13 @@ fmtp = fmt2; } else fmtp = fmt; -#define CHECK_this_length \ - PROTECT(_this); \ - thislen = length(_this); \ - if(thislen == 0) \ - error(_("coercion has changed vector length to 0")) +#define CHECK_this_length \ + do { \ + PROTECT(_this); \ + thislen = length(_this); \ + if(thislen == 0) \ + error(_("coercion has changed vector length to 0")); \ + while (0) /* Now let us see if some minimal coercion would be sensible, but only do so once, for ns = 0: */
______________________________________________ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel