fix(pproc): 修复宏参数解析中的空白字符处理问题

- 在宏参数解析过程中使用 scc_lexer_next_non_blank 替代直接的 ring 操作,
  确保正确跳过空白字符

- 更新 scc_pproc_expand_by_src 和 rescan 函数中使用
  scc_lexer_peek_non_blank 替代原来的 scc_ring_peek,
  以正确处理预处理器展开时的空白字符

- 修正测试用例中的预期输出,移除多余的空格
This commit is contained in:
zzy
2026-03-01 16:02:04 +08:00
parent 60cdfd2c33
commit 46f5328183
3 changed files with 4 additions and 4 deletions

View File

@@ -568,7 +568,7 @@ static void test_c99_docs(void) {
"\t\t\tt(10,,), t(,11,), t(,,12), t(,,) };\n",
"int j[] = { 123, 45, 67, 89,\n"
"\t\t\t10, 11, 12, };\n");
"\t\t\t10, 11, 12, };\n");
TEST_CASE("EXAMPLE 6 To demonstrate the redefinition rules, the following "
"sequence is valid.");