wit-bindgen-markdown panics when a doc-comment line begins with } and is printed inside an indented doc block (e.g. a record field doc).
poc.wit
package a:b;
world w {
export x: interface {
record r {
/// }
f: u32,
}
}
}
Crash:
thread 'main' panicked at crates/core/src/source.rs:102:9:
attempt to subtract with overflow
Other backends do not crash on this WIT.
wit-bindgen version: 0.50.0
OS: Ubuntu 22.04.5 LTS (x86_64)