Unified · Split
| @@ -2640,7 +2640,7 @@ static int *macro_arg_subst(Sym **nested_list, const int *macro_str, Sym *args) · 2639 unmodified lines | |||
| 2640 | tok_str_add2(&str, t1, &cval); | 2640 | tok_str_add2(&str, t1, &cval); |
| 2641 | } | 2641 | } |
| 2642 | } | 2642 | } |
| 2643 | } else { | 2643 | } else if (*st != TOK_PLCHLDR) { |
| 2644 | /* NOTE: the stream cannot be read when macro | 2644 | /* NOTE: the stream cannot be read when macro |
| 2645 | substituing an argument */ | 2645 | substituing an argument */ |
| 2646 | macro_subst(&str, nested_list, st, NULL); | 2646 | macro_subst(&str, nested_list, st, NULL); |
| @@ -0,0 +1,9 @@ | |||
| 1 | #include <stdio.h> | ||
| 2 | |||
| 3 | #define T(a,b,c) a b c | ||
| 4 | |||
| 5 | int main(void) | ||
| 6 | { | ||
| 7 | printf("%d", T(1,+,2) T(+,,) T(,2,*) T(,7,) T(,,)); | ||
| 8 | return 0; | ||
| 9 | } | ||
| @@ -0,0 +1 @@ | |||
| 1 | 17 | ||
| @@ -89,7 +89,9 @@ TESTS = \ · 88 unmodified lines | |||
| 89 | 67_macro_concat.test \ | 89 | 67_macro_concat.test \ |
| 90 | 68_macro_param_list_err_1.test \ | 90 | 68_macro_param_list_err_1.test \ |
| 91 | 69_macro_param_list_err_2.test \ | 91 | 69_macro_param_list_err_2.test \ |
| 92 | 70_floating_point_literals.test | 92 | 70_floating_point_literals.test \ |
| 93 | 71_macro_empty_arg.test \ | ||
| 94 | |||
| 93 | 95 | ||
| 94 | # 34_array_assignment.test -- array assignment is not in C standard | 96 | # 34_array_assignment.test -- array assignment is not in C standard |
| 95 | 97 | ||