Skip to content

Commit e98669a

Browse files
authored
Rollup merge of #89906 - yuvaldolev:move-format-version-to-rustdoc-json-types, r=CraftSpider
Moved format-version constant to rustdoc-json-types Addresses #88620 Moved format-version constant from rustdoc to rustdoc-json-types.
2 parents e56b5ee + 43f4ef5 commit e98669a

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

src/librustdoc/json/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@ impl<'tcx> FormatRenderer<'tcx> for JsonRenderer<'tcx> {
255255
)
256256
})
257257
.collect(),
258-
format_version: 9,
258+
format_version: types::FORMAT_VERSION,
259259
};
260260
let mut p = self.out_path.clone();
261261
p.push(output.index.get(&output.root).unwrap().name.clone().unwrap());

src/rustdoc-json-types/lib.rs

+3
Original file line numberDiff line numberDiff line change
@@ -510,5 +510,8 @@ pub struct Static {
510510
pub expr: String,
511511
}
512512

513+
/// rustdoc format-version.
514+
pub const FORMAT_VERSION: u32 = 9;
515+
513516
#[cfg(test)]
514517
mod tests;

0 commit comments

Comments
 (0)