fix(prose): Decl names are identifiers; skip non-decl tick spans
Reject `` `n+1` `` as Decl, and when skipping non-decl `` `…` `` advance past the closing tick so inner `*` cannot open italic (fixes `` `OPENAI_*` `` in ext/ai/llm). Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
c8f41164c5
commit
114fd53cd1
5 files changed
+67
-3
No files matched your search
@@ -3878,3 +3878,8 @@ fn markup_v03_dynamic_footnote() {
|
||||
fn markup_v03_leading_backtick_decl() {
|
||||
assert_out_v03("tests/markup-v03/leading-backtick-decl.mq.md", "ok");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn markup_v03_decl_ident_only() {
|
||||
assert_out_v03("tests/markup-v03/decl-ident-only.mq.md", "42");
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
---
|
||||
title: `` `n+1` `` is not a Decl name
|
||||
description: Only identifier Decl names elevate; `` `n+1` `` stays narrative
|
||||
---
|
||||
|
||||
## 加一
|
||||
|
||||
输入变量`n`。**n=n+1**返回*n*。
|
||||
|
||||
旁注里的`n+1`不是形参名。
|
||||
|
||||
# main
|
||||
|
||||
**r = 加一 41**
|
||||
**print text=r**
|
||||
Reference in new issue
Block a user