Closed
Description
// Signifigant whitespace
pub struct Foo;
gives
"a:2:9232:1965-0:3:1539": {
"attrs": [],
"crate_id": 0,
"deprecation": null,
"docs": null,
"id": "a:2:9232:1965-0:3:1539",
"inner": {
"blanket_impl": null,
"for": {
"inner": {
"args": {
"angle_bracketed": {"args": [], "bindings": []}
},
"id": "0:3:1539",
"name": "Foo",
"param_names": []
},
"kind": "resolved_path"
},
"generics": {"params": [], "where_predicates": []},
"is_unsafe": false,
"items": [],
"negative": false,
"provided_trait_methods": [],
"synthetic": true,
"trait": {
"inner": {
"args": {
"angle_bracketed": {"args": [], "bindings": []}
},
"id": "2:9232:1965",
"name": "RefUnwindSafe",
"param_names": []
},
"kind": "resolved_path"
}
},
"kind": "impl",
"links": {},
"name": null,
"span": {
"begin": [1, 0],
"end": [1, 0],
"filename": "bad.rs"
},
"visibility": "default"
}
with a given span of {"begin": [1, 0], "end": [1, 0], "filename": "bad.rs" }
, which is not correct.
I think the span should probably be None
/null
in this case, which is suported without changing the schema (span: Option<Span>
in rustdoc_json_types::Item
@rustbot modify labels: +T-rustdoc +A-rustdoc-json