mirror of
https://github.com/ziglang/zig.git
synced 2026-01-21 06:45:24 +00:00
autodoc: anonymous struct type indentation fix
This commit is contained in:
parent
02bc6356d7
commit
14bf20daeb
@ -1789,7 +1789,7 @@ const NAV_MODES = {
|
||||
if (structObj.fields.length > 1 && opts.wantHtml) {
|
||||
indent = " "
|
||||
}
|
||||
if (opts.indent) {
|
||||
if (opts.indent && structObj.fields.length > 1) {
|
||||
indent = opts.indent + indent;
|
||||
}
|
||||
let structNode = getAstNode(structObj.src);
|
||||
@ -1819,7 +1819,7 @@ const NAV_MODES = {
|
||||
|
||||
name += html;
|
||||
}
|
||||
if (opts.indent) {
|
||||
if (opts.indent && structObj.fields.length > 1) {
|
||||
name += opts.indent;
|
||||
}
|
||||
name += "}";
|
||||
|
||||
@ -3628,7 +3628,7 @@ fn tryResolveRefPath(
|
||||
}
|
||||
|
||||
if (self.pending_ref_paths.get(&path[path.len - 1])) |waiter_list| {
|
||||
// It's important to de-register oureslves as pending before
|
||||
// It's important to de-register ourselves as pending before
|
||||
// attempting to resolve any other decl.
|
||||
_ = self.pending_ref_paths.remove(&path[path.len - 1]);
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user