File tree 2 files changed +20
-3
lines changed
2 files changed +20
-3
lines changed Original file line number Diff line number Diff line change @@ -201,7 +201,8 @@ impl<'tcx> FormatRenderer<'tcx> for JsonRenderer<'tcx> {
201
201
202
202
types:: ItemEnum :: Method ( _)
203
203
| types:: ItemEnum :: AssocConst { .. }
204
- | types:: ItemEnum :: AssocType { .. } => true ,
204
+ | types:: ItemEnum :: AssocType { .. }
205
+ | types:: ItemEnum :: PrimitiveType ( _) => true ,
205
206
types:: ItemEnum :: Module ( _)
206
207
| types:: ItemEnum :: ExternCrate { .. }
207
208
| types:: ItemEnum :: Import ( _)
@@ -216,8 +217,7 @@ impl<'tcx> FormatRenderer<'tcx> for JsonRenderer<'tcx> {
216
217
| types:: ItemEnum :: Static ( _)
217
218
| types:: ItemEnum :: ForeignType
218
219
| types:: ItemEnum :: Macro ( _)
219
- | types:: ItemEnum :: ProcMacro ( _)
220
- | types:: ItemEnum :: PrimitiveType ( _) => false ,
220
+ | types:: ItemEnum :: ProcMacro ( _) => false ,
221
221
} ;
222
222
let removed = self
223
223
. index
Original file line number Diff line number Diff line change
1
+ // compile-flags: --document-private-items
2
+
3
+ // Regression test for <https://github.com/rust-lang/rust/issues/98006>.
4
+
5
+ #![ feature( rustdoc_internals) ]
6
+ #![ feature( no_core) ]
7
+
8
+ #![ no_core]
9
+
10
+ // @has primitive_overloading.json
11
+ // @has - "$.index[*][?(@.name=='usize')]"
12
+ // @has - "$.index[*][?(@.name=='prim')]"
13
+
14
+ #[ doc( primitive = "usize" ) ]
15
+ /// This is the built-in type `usize`.
16
+ mod prim {
17
+ }
You can’t perform that action at this time.
0 commit comments